sendmail appends server name to external domains when relaying

Posted by Chris on Server Fault See other posts from Server Fault or by Chris
Published on 2013-11-06T17:09:37Z Indexed on 2013/11/06 21:57 UTC
Read the original article Hit count: 191

Filed under:
|

My server is set to send all email to a corporate relay server. For the company domain, it works perfectly.

I've recently found emails being sent to an outside domain are getting the hostname of my server appended to the email prior to being sent. Here is the log entry for one such attempt.

Nov  6 09:46:45 myservername sendmail[45023]: rA6EkjiI045023: [email protected], delay=00:00:00, xdelay=00:00:00, mailer=relay, pri=30590, relay=[127.0.0.1] [127.0.0.1], dsn=2.0.0, stat=Sent (rA6Ekj2g045037 Message accepted for delivery)
Nov  6 09:46:45 myservername sendmail[45061]: rA6Ekj2g045037: to=<[email protected]>, delay=00:00:00, xdelay=00:00:00, mailer=relay, pri=120885, relay=relay.company.com [x.x.x.x], dsn=2.0.0, stat=Sent (ok:  Message 342335947 accepted)

Notice the email address difference between it being accepted by my server for delivery (correct email address), and being sent and accepted by the corporate relay (incorrect with server name appended).

To make it more interesting, the application on my server uses email for user account verification/activation. In August, this particular user was able to register his account and activate it. I have made no configuration changes to mail since setting the server up over a year ago.

DNS is also a corporate service. I've never touched my /etc/resolv.conf configuration.

domain company.com
nameserver <ip1>
nameserver <ip2>
search myservername

Thanks!

© Server Fault or respective owner

Related posts about linux

Related posts about sendmail