The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

mail to localhost is bouncing

Discussion in 'E-mail Discussions' started by ShirazDindar, May 29, 2007.

  1. ShirazDindar

    ShirazDindar Member

    Joined:
    Jan 19, 2006
    Messages:
    22
    Likes Received:
    0
    Trophy Points:
    1
    Hi,

    When the server sends mail to root@localhost (eg. rootkit hunter does this), the mail is bouncing back to the sender (which forwards to me), with "unrouteable mail domain 'localhost'".

    "localhost" is a valid entry in the etc/hosts file. Is there something I need to configure in Exim to get it to send to the localhost properly? Seems so basic I can't figure why it wouldn't work out of the box.


    Thanks,

    Shiraz
     
  2. bashcpanel

    bashcpanel Well-Known Member

    Joined:
    Apr 15, 2007
    Messages:
    48
    Likes Received:
    0
    Trophy Points:
    6
    Hi Shiraz,

    Whats does exim error log say ?

    tail -f /var/log/exim_errorlog
     
  3. cPanelNick

    cPanelNick Administrator
    Staff Member

    Joined:
    Mar 9, 2015
    Messages:
    3,426
    Likes Received:
    2
    Trophy Points:
    38
    cPanel Access Level:
    DataCenter Provider
    Change your domainlist local_domains to


    domainlist local_domains = lsearch;/etc/localdomains : localhost



    in the advanced exim editor.

    better yet.. don't send root mail.
     
  4. bashcpanel

    bashcpanel Well-Known Member

    Joined:
    Apr 15, 2007
    Messages:
    48
    Likes Received:
    0
    Trophy Points:
    6
    ooooops sorry ... tail -f /var/log/exim_mainlog not exim_errorlog :p
     
  5. ShirazDindar

    ShirazDindar Member

    Joined:
    Jan 19, 2006
    Messages:
    22
    Likes Received:
    0
    Trophy Points:
    1
    thanks guys

    Thanks to both of you...

    I followed cpanelnick's advice and edited the Exim conf file and now it works. Following your other suggestion, I *did* try to change the rkhunter email address to something other than root, but I couldn't find this configuration option in rkhunter... just wondering why it would be a bad idea for emails to go to root, though?


    On a related note, I find this whole scenario strange because this is on a new server with a default Cpanel install on a default Fedora 4 install. ie. rkhunter defaulted to root as the email address, and Exim defaulted to not handling such emails properly. I'm wondering how come others haven't experienced the problem... ie. couldn't find anything about it on these forums nor Google. Thoughts, anyone?


    Thanks again to both of you...

    Shiraz
     
Loading...

Share This Page