On Tue, 2009-06-23 at 16:42 +0200, list...@gmx.de wrote:
>   passdb:
>     driver: pam
>   passdb:
>     driver: sql
>     args: /etc/dovecot/dovecot-sql.conf

Do you really want to have system users too? You anyway should put pam
after the sql, because now all SQL user logins are probably delayed by a
few seconds because of the PAM delay.

>   userdb:
>     driver: passwd
>   userdb:
>     driver: sql
>     args: /etc/dovecot/dovecot-sql.conf
..
> password_query = SELECT username AS user, password, '/drbd/mail/vmail/%d/%n' 
> AS userdb_home, 'maildir:/drbd/mail/vmail/%d/%n' AS userdb_mail, 5001 AS 
> userdb_uid, 5001 AS userdb_gid FROM mailbox WHERE username = '%u' AND active 
> = '1'

You're also not using userdb prefetch, so all these usedb_* fields are
ignored here.

> (...)
> user_query = SELECT '/drbd/mail/vmail/%d/%n' AS home, 
> 'maildir:/drbd/mail/vmail/%d/%n' AS mail, 5001 AS uid, 5001 AS gid, 
> concat('*:storage=', quota, 'B') AS quota_rule FROM mailbox WHERE username = 
> '%u' AND active = '1'

This looks correct.

Looks like you already have mail_debug=yes and auth_debug=yes. What does
Dovecot log when user logs in and sees wrong quota?

Attachment: signature.asc
Description: This is a digitally signed message part

Reply via email to