If your Postfix mail server has multiple IP addresses, it will use the same SMTP hostname greeting on every IP Address. This may cause a problem since some mail servers check the SMTP hostname banner to see if the hostname points to the same mail server. If not, any mail you send may be rejected or handled as spam. You can confirm if you have this problem by getting a DNS report on your domain name.

DNS ReportSample DNS report, the hostnames are not real. Note that it shows the same SMTP banner 220 mail.acme.local ESMTP Postfix from the two hostnames, mail.acme.local and mail2.acme.local.
Edit master.cf1. Edit the file /etc/postfix/master.cf and change the line below from
smtp inet n - n - - smtpd
to this
localhost:smtp  inet n - n - - smtpd
ipaddress1:smtp inet n - n - - smtpd
ipaddress2:smtp inet n - n - - smtpd -o myhostname=hostname2
ipaddressn:smtp inet n - n - - smtpd -o myhostname=hostnamen

The new settings above binds each ip address to a new hostname except for localhost and ipaddress1 which uses the regular hostname.

Service Configuration2. Restart the Postfix service or the MailScanner service if you have integrated MailScanner into Postfix.
DNS Report3. Check your DNS report again, you should now pass the Mailserver greeting test.

Visit the forum to ask for help or to give a comment.

Posted on 12/29/2007 and last updated on 11/7/2009
Filed under Postfix