[Dovecot] pre-1.0.rc27: Index and mbox fixes

Timo Sirainen tss at iki.fi
Sun Mar 11 21:32:31 EET 2007


On Sat, 2007-03-10 at 21:45 +0200, Timo Sirainen wrote:
> I've been doing some stress testing in the last few days and fixing all
> the errors I saw. I'm hoping that I've finally really fixed all the
> index/mbox problems. So, again I think the only thing left for v1.0 is
> the documentation. Please test this nightly snapshot before I'll release
> rc27 tomorrow:

I'm worried about the PAM crash that Chris reported, so I won't release
rc27 before that's solved.

> http://dovecot.org/nightly/dovecot-latest.tar.gz

I updated this snapshot again. Changes since yesterday:

 - I added fsync_disable setting after all. It gives 20% better
performance with some of my tests, and maybe even better with a lot of
users.

 - mbox and index files should work now perfectly in out-of-quota
conditions.

 - If some people were still having problems with Dovecot hanging, that
could have been caused by sendfile() call being used when mail had CR+LF
linefeeds. If the sendfile() didn't send the whole mail, Dovecot hanged.

I just also had an idea how filesystem quota could be handled with
maildir, as long as only Dovecot is used to add new files to maildir.
Currently saving is done in this order:

1. write mails to tmp/
2. lock dovecot-uidlist file
3. rename() mails from tmp/ to new/
4. write the new dovecot-uidlist's contents to dovecot-uidlist.lock
5. rename() dovecot-uidlist.lock to dovecot-uidlist

If I switched 3 and 4, there are only rename()s that can fail. And at
least my Linux allows rename()ing when there's no disk space left. I
hope that's the case for "out of quota" conditions too? Or does it
create a new directory entry which can in some situations cause a new
disk block allocation which will fail?..
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
Url : http://dovecot.org/pipermail/dovecot/attachments/20070311/b6b6ed9a/attachment.pgp 


More information about the dovecot mailing list