[Dovecot] "multiple quota roots" complains

Kostik koc at fax.ru
Tue Oct 13 22:00:56 EEST 2009


Hello.

Actually it is a problem for me.

Introduction:
If dovecot LDA save failed to mbox (not enough disk space, for example),
it does not do rollback. Then my mailbox was corrupted. Last message is
dropped in the middle of headers(body, attachments, etc).

Same if I use file system quota, but does not set "quota plugin"
for LDA. If user receives message which is over quota:
save failed, no rollback, mbox corrupted. But if I set
"quota plugin" for LDA, then LDA works fine.

In my case, this problem occurs when:
-- use file system quota
-- and set "quota plugin" for LDA
-- and set "multiple quota roots": dirsize + fs
-- and mail dir size less than all user files
(if user have mail and some other files on it home dir).

If user receives message which is over FS quota but under dirsize
quota, then "dirsize quota plugin" say: "OK". But "fs quota plugin"
say: "stat((null)) failed: Bad address". And LDA tries to deliver
message to mbox: save failed, no rollback, mbox corrupted.

Timo or anybody! Please! Help me! :)

=kostik

> With dovecot-1.2.6 "multiple quota roots" complains:
> "stat((null)) failed: Bad address" to log file.

> My setup is:
> ---
> plugin {
>   quota = dirsize:dirsize quota
>   quota2 = fs:fs quota:group
> }
> ---

> Complains from (plugins/quota/quota-fs.c):
> ---
> if (stat(root->>storage_mount_path, &rst) < 0) {
>        if (_root->quota->set->debug) {
>              i_error("stat(%s) failed: %m",
>                      root->storage_mount_path);
>        }
>        return FALSE;
> }
> ---
> root->>storage_mount_path is NULL here.
>
> But "single quota" setup (dirsize or fs) works fine.
>
>
> Full log (multiple quota):
> ---
> Quota root: name=dirsize quota backend=dirsize args=
> Quota rule: root=dirsize quota mailbox=* bytes=48234496 messages=0
> Quota root: name=fs quota backend=fs args=group
> mbox: data=~/:INBOX=/var/virtual/mail/I/I/koc:INDEX=MEMORY
> fs: root=/var/virtual/home/I/I/koc, index=, control=,
> inbox=/var/virtual/mail/I/I/koc
> fs quota add storage dir = /var/virtual/home/I/I/koc
> fs quota block device = nfsf:/export
> fs quota mount point = /mount/m6
> stat((null)) failed: Bad address
> stat((null)) failed: Bad address
> stat((null)) failed: Bad address
> ...
> ---

> Full log (single fs quota):
> ---
> Quota root: name=fs quota backend=fs args=group
> Quota rule: root=fs quota mailbox=* bytes=48234496 messages=0
> mbox: data=~/:INBOX=/var/virtual/mail/I/I/koc:INDEX=MEMORY
> fs: root=/var/virtual/home/I/I/koc, index=, control=,
> inbox=/var/virtual/mail/I/I/koc
> fs quota add storage dir = /var/virtual/home/I/I/koc
> fs quota block device = nfsf:/export
> fs quota mount point = /mount/m6
> quota-fs: host=nfsf, path=/export, gid=52304385, bytes
> quota-fs: gid=52304385, value=48660480, limit=52428800, active=1
> ---



More information about the dovecot mailing list