[Dovecot] Optimal quota method for SQL
Hi,
I just installed 1.2.0 and I'm gonna set up some quota on my vitual users.
I' ve got dovecot set up as LDA, and currently I'm using the dict-mysql method described for 1.2.0, but it's not really working at all.
Am I correct in assuming that with this method I can define the quota limit in my dict (sql field)?
This is my current config:
dict { quotadict = mysql:/etc/dovecot-dict-sql.conf }
plugin { quota = dict:user::proxy::quotadict quota_rule = *:storage=0:messages=0 }
protocol lda { mail_plugins = quota ..... }
I want quota to be disabled unless otherwise specified in my SQL database.
// Tom
On Jul 8, 2009, at 8:39 AM, Tom Sommer wrote:
I' ve got dovecot set up as LDA, and currently I'm using the dict- mysql method described for 1.2.0, but it's not really working at all.
dovecot -n? Log output with mail_debug=yes when saving messages?
Am I correct in assuming that with this method I can define the quota limit in my dict (sql field)?
Quota limits are defined in quota_rule setting. You can have your
userdb override the global one.
plugin { quota = dict:user::proxy::quotadict quota_rule = *:storage=0:messages=0 }
Looks ok. This should track quota, but have any limits for it. For
users that need quota just override the quota_rule.
I want quota to be disabled unless otherwise specified in my SQL
database.
I suppose you're using userdb sql?
Timo Sirainen wrote:
Am I correct in assuming that with this method I can define the quota limit in my dict (sql field)?
Quota limits are defined in quota_rule setting. You can have your userdb override the global one.
plugin { quota = dict:user::proxy::quotadict quota_rule = *:storage=0:messages=0 }
Looks ok. This should track quota, but have any limits for it. For users that need quota just override the quota_rule.
I want quota to be disabled unless otherwise specified in my SQL database.
I suppose you're using userdb sql?
I figured out the missing link was user_query not returning quota_rule, wiki didn't mention this was needed for 1.2 - or maybe I misunderstood something.
I'm puzzled as to what the dict is used for then, if not to retrieve the quota limits?
The wiki could use some love in regards to this :)
Thanks // Tom
Timo Sirainen wrote:
On Jul 9, 2009, at 6:48 AM, Tom Sommer wrote:
I'm puzzled as to what the dict is used for then, if not to retrieve the quota limits?
To keep track of the current quota usage.
Right, what backend is best performance. SQL would be nice because you can pull the current usage, but I can imagine there is going to be a lot of queries going into that, 1 per mail? Is the "maildir" backend best for quotas?
// Tom
participants (2)
-
Timo Sirainen
-
Tom Sommer