[Dovecot] Quota in mysql dict not properly recalculated on 1.2?
Joan
aseques at gmail.com
Fri Jul 2 11:06:08 EEST 2010
Good morning, I am trying to add quota storage on mysql following the
guide in the wiki http://wiki.dovecot.org/Quota/Dict, and I am having
some problems.
My setup works fine for the newly created accounts, and correctly
increases/decreases quota when necessary. The wrong part seems to be
the recalculation. It seems to me that the system doesn't count the
real occupation when it has to recreate the quota entry for a
username.
This is the case:
.- User test at testing.com has a quota 200000 bytes, I delete the entry
of the database for user, and then when I do the:
echo 'x GETQUOTAROOT Inbox' | USER=test at testing.com /usr/sbin/dovecot
--exec-mail imap
.- These are ALL the queries I see, I am missing the userdb queries to
get the real quota.
INSERT INTO quota_dovecot (bytes,username) VALUES
('0','test at testing.com') ON DUPLICATE KEY UPDATE bytes='0'
INSERT INTO quota_dovecot (messages,username) VALUES
('0','test at testing.com') ON DUPLICATE KEY UPDATE messages='0'
COMMIT
SELECT bytes FROM quota_dovecot WHERE username = 'test at testing.com'
SELECT messages FROM quota_dovecot WHERE username = 'test at testing.com'
.- And the result also seems to indicate that it's not reading the
quota from userdb
* PREAUTH [CAPABILITY IMAP4rev1 LITERAL+ SASL-IR LOGIN-REFERRALS ID
ENABLE SORT SORT=DISPLAY THREAD=REFERENCES THREAD=REFS MULTIAPPEND
UNSELECT IDLE CHILDREN NAMESPACE UIDPLUS LIST-EXTENDED I18NLEVEL=1
CONDSTORE QRESYNC ESEARCH ESORT SEARCHRES WITHIN CONTEXT=SEARCH
LIST-STATUS QUOTA] Logged in as test at testing.com
* QUOTAROOT "Inbox" "user"
* QUOTA "user" (STORAGE 0 1048576)
x OK Getquotaroot completed.
It seems to me that dovecot --exec-mail doesn't do the mysql lookups
to get the usersdb.
Note: attached are my dovecot -n output and the relevant .conf files
-------------- next part --------------
A non-text attachment was scrubbed...
Name: dovecot.conf
Type: application/octet-stream
Size: 2118 bytes
Desc: not available
Url : http://dovecot.org/pipermail/dovecot/attachments/20100702/94108ed2/attachment.obj
-------------- next part --------------
A non-text attachment was scrubbed...
Name: dovecot-sql-domain.conf
Type: application/octet-stream
Size: 442 bytes
Desc: not available
Url : http://dovecot.org/pipermail/dovecot/attachments/20100702/94108ed2/attachment-0001.obj
-------------- next part --------------
A non-text attachment was scrubbed...
Name: dovecot-dict-sql.conf
Type: application/octet-stream
Size: 311 bytes
Desc: not available
Url : http://dovecot.org/pipermail/dovecot/attachments/20100702/94108ed2/attachment-0002.obj
More information about the dovecot
mailing list