I have set up postfix using mysql but am running into a problem when trying to send mail out -- the SMTP server fails on authentication:
/var/log/mail.log:
localhost postfix/smtpd[16637]: connect from localhost.localdomain[127.0.0.1]
localhost postfix/smtpd[16637]: warning: localhost.localdomain[127.0.0.1]: SASL LOGIN authentication failed: authentication failure
localhost postfix/smtpd[16637]: lost connection after AUTH from localhost.localdomain[127.0.0.1]
localhost postfix/smtpd[16637]: disconnect from localhost.localdomain[127.0.0.1]
With further testing, it seems to me that pam-mysql is not connecting to my database properly; however, the username and password in /etc/pam.d/smtp are correct.
/var/log/auth.log:
localhost saslauthd[17901]: pam_mysql - MySQL error (Access denied for user 'mail_admin'@'localhost' (using password: YES))
localhost saslauthd[17901]: DEBUG: auth_pam: pam_authenticate failed: Authentication service cannot retrieve authentication info
localhost saslauthd[17901]: do_auth : auth failure: [user=user@domain.com] [service=smtp] [realm=domain.com] [mech=pam] [reason=PAM auth error]
I am stumped as to how to solve this, so any assistance would be greatly appreciated! :)
-
I believe the MySQL authentication data is typically stored in:
/etc/postfix/sasl/smtpd.confDaniel Vandersluis : I've got that file set up with the correct data as well. However, when I change the username it's using in `/etc/pam.d/stmp` it is reflected in the error message so I don't think that's the problem.Warner : At least right now, it's definitely the issue. The permissions, username, and/or password are incorrect. Once the database authentication issue is corrected, if things aren't working as expected, it's on to the next issue.Daniel Vandersluis : You're right, I had two u's in the password, one uppercase and one lowercase, and they were typed in the wrong order. Thanks for making me look again.From Warner
0 comments:
Post a Comment