[dovecot] Re: observations/qestions of mbox concurrency ability (Yay!) on current CVS
Timo Sirainen
tss at iki.fi
Sun Oct 20 16:47:49 EEST 2002
On Sun, 2002-10-20 at 09:38, Ian R. Justman wrote:
> Tested having Pine on the machine on which Dovecot was running, talking
> IMAP, as well as another Pine instance, this time from my Windows machine
> over the wire. Things seem to be working wonderfully. Deleted a message
> using one instance, then refreshed the list on the other. *poof* Gone.
>
> Though I'm seeing periodic "IMAP protocol error" messages in Pine, but
> they don't seem to be affecting the software's operation that I can see.
>
> Anything in particular I should be on the lookout for?
By default Dovecot uses .lock file and flock() locking. Some programs
may use fcntl() which doesn't work with flock(), but most use .lock file
as well so it doesn't really matter. I'm going to make the locking style
configurable later.
Anyway, I don't know of any reasons for mailbox corruption, but we don't
lock the mailbox when reading from it, so it is possible that someone
else might modify (expunge) the mailbox while Dovecot is reading it and
the IMAP client gets corrupted message.
I was thinking about fixing this using read-locking fcntl() / flock().
Maybe it could optionally create the .lock file as well, but that'd slow
down simultaneous reads.
Oh, and the mbox parsing code could use better checking, if there's any
bugs it will corrupt the mailbox at expunge/flag rewrite. I haven't seen
those though for the month or two that I've been using Dovecot+mbox to
read my mail.
More information about the dovecot
mailing list