On Fri, 2010-07-02 at 10:06 +0200, Joan wrote:
It seems to me that dovecot --exec-mail doesn't do the mysql lookups to get the usersdb.
Yes, you're right. --exec-mail doesn't do a userdb lookup. With v2.0 you could use "imap -u username" and it does a userdb lookup. It's seems I'm always a version before the cool feature :P, it's the
2010/7/2 Timo Sirainen <tss@iki.fi>: pain of using debian Stable ...
Did you try the quota recalculation when logging in normally, instead of with --exec-mail?
I sent a 5M mail to myself, there's the mail in inbox and the copy to sent (amounting 10M), I connected to the server and manually removed the mail (rm file). After that sending a new mail updates the quota, but it doesn't recalculate it. I only see: UPDATE quota_dovecot SET bytes=bytes+631,messages=messages+1 WHERE username = 'test@testing.com'
After deleting the entry for test@testing.com from the database, the quota gets properly recalculated.
The problem is that I rely on db quota for some accounting scritpts, and the users might not enter to their webmail or download the mail for days.
How could I trigger this quota recalculation? .- Maybe the most practical would be to have a crontab to update the real values from time to time, at least until 2.0 is not available in our environment... .- Any other solution?