Hi all
I'm not quite sure how to explain this problem, so I'll just go from the
top ;-).
System is setup on a FreeBSD with IMAP and POP3, both can use PAM and SQL
(MySQL) as login methods, though only POP3 is accessible from "the
world" - IMAP is restricted via firewall to only localhost. Simple eh?
The problem is that dovecot apparently drops the SQL part from time to time.
Though this can be fixed by HUPing the dovecotdaemon I'd rather that I
didn't have to.
I've narrowed the problem to something like this:
Over time, Dovecot/POP3/SQL combination dies - I've yet to examine if the
problem is on IMAP as well as this is only recently reported. I have never
experienced this myself since I'm using Dovecot/IMAP/PAM and this seems to
be rock solid.
The configuration looks like this:
OS: FreeBSD n/a 6.0-BETA3 FreeBSD 6.0-BETA3 #0:
MySQL: 5.0.9-beta-log
Dovecot: alpha 1 (I'll test Alpha 2 to see if the problem persists)
Compilation options for dovecot:
./configure \
--enable-ipv6=no \
--with-ldap=no \
--with-vpopmail=no \
--with-mysql \
--with-ssl=no
dovecot.conf:
base_dir = /var/run/dovecot/
protocols = imap pop3
ssl_disable = yes
disable_plaintext_auth = no
login_user = dovecot
login_process_per_connection = no
login_greeting = Ready
max_mail_processes = 1024
first_valid_uid = 1
first_valid_gid = 1
protocol imap {
}
protocol pop3 {
}
auth default {
mechanisms = plain
passdb pam {
}
userdb passwd {
}
passdb sql {
args = /usr/local/etc/dovecot/mysql.conf
}
userdb sql {
args = /usr/local/etc/dovecot/mysql.conf
}
user = root
}
-- END --
sql.conf:
driver = mysql
connect = host=localhost port=3306 dbname=N/A user=N/A password=N/A
client_flags=0
default_pass_scheme = CRYPT
password_query = SELECT password FROM mail WHERE username = '%n' and
domain= '%d'
user_query = SELECT
concat('/VIRTUAL_MAIL/',domain,'/',username,'/') as
home,concat('/VIRTUAL_MAIL/',domain,'/',username,'/') as
mail, 1 as uid, 6 as gid FROM mail WHERE username = '%n' and domain =
'%d'
-- END --
I'm sort of at a loss here since everything "seems to be working"
(tm) for one part, but not another
Hope someone has an idea ;-)
S?ren P. Skou