jmbiram
2008-05-25, 03:41 PM CDT
:mad: I get this error trying to get Dovecot to authenticate with Postfix using MySQL.
More info on the problem! Fedora 9
### /var/log/mail.log
### The mail Error Log Shows:
dovecot: May 25 08:39:52 Info: Dovecot v1.0.13 starting up
dovecot: May 25 08:39:52 Error: Auth process died too early - shutting down
dovecot: May 25 08:39:52 Error: auth(default): Unknown database driver 'mysql'
dovecot: May 25 08:39:52 Error: child 17805 (auth) returned error 89
:confused: The 89 refers to postfix uid and the mysql refers to the dovecot-mysql.conf files thats about all I know. I have no idea why the Auth process dies too early.
#### dovecot-mysql.conf ###
# The mysqld.sock socket may be in different locations in different systems
driver = mysql
connect = host=/var/lib/mysqld/mysqld.sock dbname=mails user=postfix password=xxxxx
# Alternatively you can connect to localhost as well:
#connect = host=localhost dbname=mails user=postfix password=xxxxx
password_query = SELECT concat(userid, '@', domain) AS user, password FROM users WHERE userid = '%n' AND domain = '%d'
user_query = SELECT home, uid, gid FROM users WHERE userid = '%u'
:) I would appreciate any help :?
####dovecot.conf ###
auth_verbose = yes
mail_debug = yes
base_dir = /var/run/dovecot/
protocols = imap imaps pop3 pop3s
listen = *
shutdown_clients = yes
log_path = /var/log/mail.log
info_log_path = /var/log/mail.log
log_timestamp = "%b %d %H:%M:%S "
syslog_facility = mail
disable_plaintext_auth = no
ssl_disable = no
ssl_cert_file = /etc/postfix/ssl/smtpd.crt
ssl_key_file = /etc/postfix/ssl/smtpd.key
login_chroot = yes
login_user = postfix
login_process_per_connection = yes
login_processes_count = 2
login_max_processes_count = 128
login_max_connections = 256
login_greeting = Welcome to JB's Mail Server.
login_log_format_elements = user=<%u> method=%m rip=%r lip=%l %c
login_log_format = %$: %s
default_mail_env = maildir:/var/spool/postfix/virtual/%d/%n
first_valid_uid = 89 # REMEBER THIS MUST BE CHANGED TO YOUR UID FOR "postfix" FROM /etc/passwd
pop3_uidl_format = %08Xu%08Xv
auth default {
mechanisms = PLAIN
userdb sql {
args = /etc/dovecot-mysql.conf
}
passdb sql {
args = /etc/dovecot-mysql.conf
}
user = root
count = 2
}
mail_access_groups = mail
mail_debug = yes
More info on the problem! Fedora 9
### /var/log/mail.log
### The mail Error Log Shows:
dovecot: May 25 08:39:52 Info: Dovecot v1.0.13 starting up
dovecot: May 25 08:39:52 Error: Auth process died too early - shutting down
dovecot: May 25 08:39:52 Error: auth(default): Unknown database driver 'mysql'
dovecot: May 25 08:39:52 Error: child 17805 (auth) returned error 89
:confused: The 89 refers to postfix uid and the mysql refers to the dovecot-mysql.conf files thats about all I know. I have no idea why the Auth process dies too early.
#### dovecot-mysql.conf ###
# The mysqld.sock socket may be in different locations in different systems
driver = mysql
connect = host=/var/lib/mysqld/mysqld.sock dbname=mails user=postfix password=xxxxx
# Alternatively you can connect to localhost as well:
#connect = host=localhost dbname=mails user=postfix password=xxxxx
password_query = SELECT concat(userid, '@', domain) AS user, password FROM users WHERE userid = '%n' AND domain = '%d'
user_query = SELECT home, uid, gid FROM users WHERE userid = '%u'
:) I would appreciate any help :?
####dovecot.conf ###
auth_verbose = yes
mail_debug = yes
base_dir = /var/run/dovecot/
protocols = imap imaps pop3 pop3s
listen = *
shutdown_clients = yes
log_path = /var/log/mail.log
info_log_path = /var/log/mail.log
log_timestamp = "%b %d %H:%M:%S "
syslog_facility = mail
disable_plaintext_auth = no
ssl_disable = no
ssl_cert_file = /etc/postfix/ssl/smtpd.crt
ssl_key_file = /etc/postfix/ssl/smtpd.key
login_chroot = yes
login_user = postfix
login_process_per_connection = yes
login_processes_count = 2
login_max_processes_count = 128
login_max_connections = 256
login_greeting = Welcome to JB's Mail Server.
login_log_format_elements = user=<%u> method=%m rip=%r lip=%l %c
login_log_format = %$: %s
default_mail_env = maildir:/var/spool/postfix/virtual/%d/%n
first_valid_uid = 89 # REMEBER THIS MUST BE CHANGED TO YOUR UID FOR "postfix" FROM /etc/passwd
pop3_uidl_format = %08Xu%08Xv
auth default {
mechanisms = PLAIN
userdb sql {
args = /etc/dovecot-mysql.conf
}
passdb sql {
args = /etc/dovecot-mysql.conf
}
user = root
count = 2
}
mail_access_groups = mail
mail_debug = yes