[Dovecot] index

Timo Sirainen tss at iki.fi
Sun Jun 17 22:10:05 EEST 2007


(Ccing again the list in case someone else has similar problems)

On Sun, 2007-06-17 at 20:14 +0200, Lucas -LandM- wrote:
> Hi Timo,
> 
>    I patched the source and same result. We think the problem is because 
> everytime user access to his mailbox, dovecot do the index again. And it 
> consume near the 80% in iowait because, as strace shows, read all mails.

The problem isn't that Dovecot indexes it. The problem is that Dovecot
ISN'T indexing it.

Dovecot commits changes to cache file only after a FETCH command
finished successfully. So if the client is disconnected in the middle of
doing the FETCH, all of the work that Dovecot did so far gets lost on
Dovecot's side. And apparently your client also starts everything from
the beginning, even though it already knew some of the messages' sizes..

So the previous patch I sent was supposed to prevent this because
originally Dovecot was the one that disconnected the client. It logged
"Disconnected for inactivity in reading our output" as the disconnect
reason. This shouldn't happen anymore after you patched it, so why did
the client still get disconnected?

Anyway, here's another patch that makes Dovecot not forget all of its
work if the client gets disconnected in the middle of FETCH:
http://hg.dovecot.org/dovecot-1.0/rev/e1cd11c5e00a

If the client is still disconnecting, it probably takes a couple of
tries to get everything read and cached, but after that it should all
work nicely.

Here's a similar patch for POP3:
http://hg.dovecot.org/dovecot-1.0/rev/86766f448e50
-------------- 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/20070617/cf51580e/attachment.bin 


More information about the dovecot mailing list