Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

How can I send a single email from the server? Command line?

Discussion in 'E-mail Discussion' started by lenashore, Jun 3, 2015.

  1. lenashore

    lenashore Member

    Joined:
    Feb 11, 2011
    Messages:
    12
    Likes Received:
    0
    Trophy Points:
    51
    My server got on a blacklist yesterday. I found the offending problem and cleaned it up. So, now I am trying to get delisted. One of things I need to do is to send an email from the offending server with a special subject line provided for me:

    You must be able to send an e-mail with an verifycode from xxx.xx.xxx.xx to delist.
    I don't have any email accounts on this server. I do have some Wordpress sites that have email forms - but I don't know how to SEND an email to these guys. Clearly I could set up a form on a server to send mail and send it (the damn hackers do it) - but I was hoping there was more of a one-time solution... Maybe sending from the command-line somehow? Or is there an option to send a single mail from the WHM someplace?

    Any ideas? I am feeling a little dumb here.
     
  2. madmanmachines

    madmanmachines Well-Known Member

    Joined:
    Nov 28, 2014
    Messages:
    94
    Likes Received:
    4
    Trophy Points:
    8
    cPanel Access Level:
    Root Administrator
    Hi,

    You'll need to receive mail from the same address that you send the delist request from, so you should probably just create a temporary email account. As well, are you sure the RBL requires the delist request to be sent from the server?

    Thanks,
     
  3. lenashore

    lenashore Member

    Joined:
    Feb 11, 2011
    Messages:
    12
    Likes Received:
    0
    Trophy Points:
    51
    It did say "from the IP it was listed". So, I'm inferring it needs to come from the server.

    I did find a possible solution from the command line a few minutes ago. I should know in a few hours if it worked. As if it worked, I should be delisted within 3 hours.

    Code:
    [root@tecadmin ~]# mail -s "Test Subject" user@example.com < /dev/null
    
     
  4. cPanelMichael

    cPanelMichael Technical Support Community Manager
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    45,442
    Likes Received:
    1,961
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Twitter:
    Hello,

    While it may work sending from the command line, is there any reason you can't create an email account for a domain name hosted on your server?

    Thank you.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  5. lenashore

    lenashore Member

    Joined:
    Feb 11, 2011
    Messages:
    12
    Likes Received:
    0
    Trophy Points:
    51
    I suppose I could. There are no mail accounts at all on the server now. I guess I assumed if I made an account it would add extra software to the server. Also, all sites are set up to use outside mail servers. Would that matter? Maybe that is a non-issue?
     
  6. cPanelMichael

    cPanelMichael Technical Support Community Manager
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    45,442
    Likes Received:
    1,961
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Twitter:
    No extra software is installed as cPanel already includes email functionality. That being said, if the domain name resolves to a remote server and email is handled remotely, then it's likely a better idea to send the email as you did.

    Thank you.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  7. lenashore

    lenashore Member

    Joined:
    Feb 11, 2011
    Messages:
    12
    Likes Received:
    0
    Trophy Points:
    51
    Thanks for the clarification on how it works. Much appreciated. So much to learn, but that can be fun.
     
Loading...

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice