Postfix relayhost to Smart host

Thanks to http://www.freelock.com/kb/postfix-relayhost

These are the basic steps to set up Postfix to use SMTP Authentication to send mail through a relay host.

  • Set up a password maps file (/etc/postfix/sasl_passwd) as follows:

mail.ispserver.com username:password

  • chown root:root /etc/postfix/sasl_passwd; chmod 600 /etc/postfix/sasl_passwd
  • postmap /etc/postfix/sasl_passwd
  • In /etc/postfix/main.cf:

relayhost = mail.ispserver.com
smtp_sasl_auth_enable = yes
smtp_sasl_password_maps = hash:/etc/postfix/sasl_passwd
smtp_sasl_security_options =

  • postfix reload