[Dovecot] Temporary files
Timo Sirainen
tss at iki.fi
Thu Jul 15 19:21:24 EEST 2010
On Thu, 2010-07-15 at 08:54 -0700, Daniel L. Miller wrote:
> "/var/spool contains data which is awaiting some kind of later
> processing. Data in /var/spool represents work to be done in the future
> (by a program, user, or administrator); often data is deleted after it
> has been processed."
I don't think this is what the files are. They are created and they're
immediately unlinked before anything is even written to them. The files
are treated kind of like being virtual memory, but since they're stored
in filesystem rather than kept in memory, the kernel knows that under
memory pressure it's better to write them to disk than move memory pages
to swap.
So there is no "awaiting" or "work to be done in future". And data isn't
deleted after it has been processed, it's deleted even before processing
begins..
BTW. I've already committed the mail_temp_dir with a default to /tmp. I
forgot also that nowadays if writing to the temp file fails, the mail
delivery won't fail but instead everything is moved into memory. So a
default /tmp isn't that bad anymore.
More information about the dovecot
mailing list