I am having what appears to be the same problem as several other people with this setup. I haven't seen anyone find the answer yet though. I am able to receive e-mail with no problem, but I am getting some SASL authentication errors when I try to send e-mail out. The follwing is in the mail.log file when I try to send e-mail:
May 9 19:08:35 mail postfix/smtpd: connect from host[192.168.1.12]
May 9 19:08:36 mail postfix/smtpd: warning: host[192.168.1.12]: SASL LOGIN authentication failed: authentication failure
May 9 19:08:36 mail postfix/smtpd: lost connection after AUTH from host[192.168.1.12]
May 9 19:08:36 mail postfix/smtpd: disconnect from host[192.168.1.12]
I also see this in the auth.log:
May 9 19:08:36 mail saslauthd: pam_mysql - SELECT returned no result.
May 9 19:08:36 mail saslauthd: DEBUG: auth_pam: pam_authenticate failed: User not known to the underlying authentication module
May 9 19:08:36 mail saslauthd: do_auth : auth failure: [user=test] [service=smtp] [realm=thewhiterabbit.org] [mech=pam] [reason=PAM auth error]
So it seems that saslauthd can't pull the needed info from the mysql database. Here are the contents of my pertinent config files:
# Settings for saslauthd daemon
# Should saslauthd run automatically on startup? (default: no)
PARAMS="-m /var/spool/postfix/var/run/saslauthd -r"
auth required pam_mysql.so user=mail_admin passwd=<password> host=127.0.0.1 db=mail table=users usercolumn=email passwdcolumn=password crypt=1
account sufficient pam_mysql.so user=mail_admin passwd=<password> host=127.0.0.1 db=mail table=users usercolumn=email passwdcolumn=password crypt=1
mech_list: plain login
sql_select: select password from users where email = '%u'
SASL portions of /etc/postfix/main.cf:
smtpd_sasl_auth_enable = yes
broken_sasl_auth_clients = yes
smtpd_recipient_restrictions = permit_mynetworks, permit_sasl_authenticated, reject_unauth_destination
I am at a real loss here. All of the configs appear to be correct. Obviously the database itself works since the checking mail works fine. I did spot check things with PhpMyAdmin though and everything looks correct. Any thoughts on what could be wrong here?