public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* Very slow header cache in mutt if the maildir is on ext3
@ 2008-12-17  0:16 Tino Keitel
  2008-12-17  0:52 ` Tino Keitel
  0 siblings, 1 reply; 7+ messages in thread
From: Tino Keitel @ 2008-12-17  0:16 UTC (permalink / raw)
  To: linux-kernel

Hi,

I suffered from very long delays (like one minute) when opening
maildirs with a few thousand mails on my laptop.  I did some testing on
my desktop in a very similar environment (LVM, dm-crypt, 2,5" hard
disk, identical mutt configuration), which worked as quick as expected. 
However, I tested with the maildir on XFS.  When I switched to ext3,
things got slow again.  Then I discovered that the mutt header cache
file is the culprit.  I already made a backup and restore, so the file
system is in a fresh state.  I also removed the old header cache before
testing.

In strace, I see that during the delay read() and lseek() were called
to read the header cache.  If I flush all caches, and then read only
the header cache back into the cache using dd, it works as quick as
expected (only a few seconds).

The strange thing is that in both cases (maildir on ext3 and maildir on
XFS), the header cache file is stored on a separate file system on a
different hard disk on an XFS file system.  I don't get the point why
reading the header cache from this XFS file system is so slow when the
maildir is on ext3, and fast when the maildir is on XFS.

Here are strace excerpts for XFS and ext3, taken with "strace -f -s0
-tt" after doing "echo 7 > /proc/sys/vm/drop_caches":

http://tikei.de/mutt_hcache_xfs.txt
http://tikei.de/mutt_hcache_ext3.txt

Note the start and end times. The ext3 case took nearly 18 seconds, the
XFS case took 3 seconds.

Regards,
Tino

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2008-12-17 16:17 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-12-17  0:16 Very slow header cache in mutt if the maildir is on ext3 Tino Keitel
2008-12-17  0:52 ` Tino Keitel
2008-12-17  1:03   ` Tino Keitel
2008-12-17  3:25   ` Theodore Tso
2008-12-17  9:10     ` Tino Keitel
2008-12-17 12:32       ` Theodore Tso
2008-12-17 16:17         ` Tino Keitel

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox