I followed the How-To for Virtual Users and Domains with Postfix, Courier and MySQL and got it working great, then did a yum update after a few months and the update broke courier authentication on my production server and users couldn't send/receive any e-mail, the maillog had errors like:
warning: SASL authentication failure: cannot connect to Courier authdaemond: Permission denied
when attempting to send from Outlook, and:
pop3d: LOGIN FAILED, firstname.lastname@example.org, ip=[::ffff:126.96.36.199]
Jan 25 11:41:22 mail2 pop3d: authentication error: Input/output error
Jan 25 11:41:22 mail2 pop3d: Connection, ip=[::ffff:188.8.131.52]
Jan 25 11:41:23 mail2 authdaemond: failed to connect to mysql server (server=mysql.example.com, userid=admin): Unknown MySQL server host 'mysql.e
when trying to use imap webmail.
It turns out that yum updates courier authentication, but when it does it takes your authmysqlrc file and backs it up then makes a new one with what it thinks your settings are, but they are all wrong. So you have to restore the /etc/authlib/authmysqlrc.bak to authmyqlrc and then it works.
Also, it screws up the permissions on authdaemon, so you have to run this to fix it:
chmod o+x /var/spool/authdaemon
Hope this helps the next person not spend hours like I did, and keep your e-mail users happy