[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: reading an empty directory after reboot is very slow

On 2015-04-21 12:47:14 -0500, David Wright wrote:
> Quoting Vincent Lefevre (vincent@vinc17.net):
> > This mailbox is constantly open in a Mutt running in screen (in
> > read-only mode). I often read it, and I modify it from time to time,
> > either by adding new messages in the usual way, or by modifying some
> > header of existing messages with some tool of mine (in which case, I
> > restart Mutt to take the changes into account).
> I guess I find it hard (not knowing what all these emails are) to get
> my head around needing an email-style random access to 145k emails in
> one folder.

I can then do any filtering I like to search for an old e-mail
instead of having to look at several folders individually.

> > When I wrote my tool, I thought that such a cached mapping would be
> > useless because the mailbox would have to be read by Mutt anyway.
> > So, there's still something I don't understand: after dropping the
> > caches, why is Mutt fast to read the mailbox (about 1 minute), but
> > not my tool (about 30 minutes)?
> Because mutt caches, and its caches are persistent.
> The default location (not in the man page, I think) is
> ~/.mutt-cache/header-cache/
> for the headers, and its parent for the emails themselves.

No, I don't use caches (the header cache is not enabled and the
~/.mutt-cache directory doesn't exist).

> > > Have you considered running a local IMAP server to handle this (and
> > > any other) maildir?
> > 
> > There would be other problems. All the tools would have to talk
> > with this server... and for instance, mairix doesn't support IMAP.
> Is this correct?
> http://www.gnu.org/software/emacs/manual/html_node/gnus/Setting-up-mairix.html

This seems to be something different (nnmairix), which is not in Debian.
For mairix:

 mairix is a program for indexing and searching locally stored email messages.
 mairix supports Maildir, MH folders, and mbox formats.

> But I don't understand why, if you're running mairix, you need to scan the
> emails yourself. Hasn't mairix done this already? (As well as mutt.)

Only once for indexing. This is persistent after reboots and not
used by Mutt at all.

Vincent Lefèvre <vincent@vinc17.net> - Web: <https://www.vinc17.net/>
100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/>
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)

Reply to: