Maildir
|
Maildir is a format for an e-mail spool that does not require file locking to maintain message integrity, because the messages are kept in separate files. It consists of a directory named Maildir with three subdirectories, tmp, new, and cur.
The process that delivers mail writes it to tmp with a filename that consists of the concatenation of the process ID, the time, and the hostname, then when it is finished moves it to new. This is to avoid that a mail user agent would read a partial message while it is being delivered. The process that reads mail moves messages from new to cur before reading them, appending an info suffix to the filename. The info suffix consists of a colon (to separate the unique part of the filename from the actual information), a '2', a comma and flags to the filename. The '2' specifies, loosely speaking, the version of the information that follows the comma. '2' is the only currently officially specified version, '1' being an experimental version. One can only assume that it was used while the Maildir format was under development.
For more information see http://www.qmail.org/qmail-manual-html/man5/maildir.html and http://cr.yp.to/proto/maildir.html.
Software that supports Maildir includes:
- Postfix
- Qmail
- Courier IMAP
- Exim
- procmail
- Mutt
- KMail
- safecat, which provides a script called maildir for use in pipelines
- Novell Evolution