[Dovecot] expire db(s)?
with two separate dovecot/backend servers accessing one central mysql server, will it be ok to have them both use the same expires table? Or will that confuse the actual dovecot --exec-mail ext /usr/local/libexec/dovecot/expire-tool.sh cronjob since some of the entries mailboxes won't exist locally?
Ben
On Dec 18, 2009, at 5:57 PM, ben@electricembers.net wrote:
with two separate dovecot/backend servers accessing one central mysql server, will it be ok to have them both use the same expires table? Or will that confuse the actual dovecot --exec-mail ext /usr/local/libexec/dovecot/expire-tool.sh cronjob since some of the entries mailboxes won't exist locally?
It'll break. If userdb lookup fails, expire-tool thinks that the user no longer exists and deletes the row from database. If it succeeds but the mail directory doesn't exist, it'll think the mailbox was deleted and deletes the row from database.
we've got the expire plugin configured, and it's properly inserting rows to the db. But something's slightly wrong with runing the actual expire-tool(.sh) job. It seems to want to find the maildirs in a directory inside our maildirs called Maildir (which we don't have.) It's no biggie if we need to just wait for v2 to get expire working ;) ::::
# /usr/local/sbin/dovecot --exec-mail ext /usr/local/libexec/dovecot/expire-tool.sh --test
Info: Loading modules from directory: /usr/local/lib/dovecot/imap Info: Module loaded: /usr/local/lib/dovecot/imap/lib10_quota_plugin.so Info: Module loaded: /usr/local/lib/dovecot/imap/lib20_expire_plugin.so Info: Quota root: name=user backend=dict args=:proxy::quotadict Info: Quota warning: bytes=0 (95%) messages=0 command=/usr/local/ee/quota-warning.sh 95 Info: Quota warning: bytes=0 (80%) messages=0 command=/usr/local/ee/quota-warning.sh 80 Info: expire: pattern=*.Trash type=expunge secs=86400 Info: expire: pattern=*.Spam type=expunge secs=86400 Info: expire: pattern=*.Virus type=expunge secs=86400 Info: auth input: home=/home/npomail/virt.monopod.net/a@virt.monopod.net/ Info: auth input: uid=1003 Info: auth input: gid=1003 Info: auth input: mail=maildir:/home/npomail/virt.monopod.net/a@virt.monopod.net/ Info: auth input: quota_rule=*:storage=1024000000B Info: auth input: sieve=/home/npomail/virt.monopod.net/a@virt.monopod.net/sieve-filterfile Info: auth input: sieve_dir=/home/npomail/virt.monopod.net/a@virt.monopod.net/ Info: dict quota: user=a@virt.monopod.net, uri=proxy::quotadict, noenforcing=0 Info: Namespace: type=private, prefix=INBOX., sep=., inbox=yes, hidden=no, list=yes, subscriptions=yes Info: cydir: mailbox location not given Info: cydir: Couldn't create mail storage : Root mail directory not given Info: dbox: mailbox location not given Info: dbox: Couldn't create mail storage : Root mail directory not given Info: maildir: access(/home/npomail/virt.monopod.net/a@virt.monopod.net//Maildir, rwx): failed: No such file or directory Info: maildir: couldn't find root dir Info: maildir: Couldn't create mail storage : Root mail directory not given Info: mbox: root: access(/home/npomail/virt.monopod.net/a@virt.monopod.net//mail, rwx) failed: No such file or directory Info: mbox: root: access(/home/npomail/virt.monopod.net/a@virt.monopod.net//Mail, rwx) failed: No such file or directory Info: mbox: checking if we are chrooted: Info: mbox autodetect: data= Info: mbox autodetect: has .imap/: stat(/.imap) failed: No such file or directory Info: mbox autodetect: has inbox: stat(/inbox) failed: No such file or directory Info: mbox autodetect: has mbox: stat(/mbox) failed: No such file or directory Info: mbox: root mail directory not found Info: mbox: Couldn't create mail storage : Autodetection failed Info: raw: mailbox location not given Info: raw: Couldn't create mail storage : Root mail directory not given Info: shared: Couldn't create mail storage : Shared mailbox location not prefixed with driver Error: Namespace 'INBOX.': Mail storage autodetection failed with home=/home/npomail/virt.monopod.net/a@virt.monopod.net/ Info: User lookup failed: a@virt.monopod.net Info: a@virt.monopod.net/INBOX.Trash: stop, expire time in future: Sat Dec 19 19:12:43 2009
On Sat, 2009-12-19 at 09:21 -0800, ben@electricembers.net wrote:
we've got the expire plugin configured, and it's properly inserting rows to the db. But something's slightly wrong with runing the actual expire-tool(.sh) job. It seems to want to find the maildirs in a directory inside our maildirs called Maildir (which we don't have.) It's no biggie if we need to just wait for v2 to get expire working ;)
Looks like when you have namespaces defined, expire-tool doesn't understand that the mail location can be overridden by userdb lookup. You could remove all namespaces from expire-tool's .conf file to make it work..
participants (2)
-
ben@electricembers.net
-
Timo Sirainen