Penguin

A robust MailBox format for Unix that gets around a lot of the serious limitations on the old and creaking MBox format.

Like MH, it stores each Email in a file of its own, but does not require any locking, ever. This avoids many problems with concurrent updates, such as that some programs use flock(2) while others use fcntl(2), or that NFS FileSystems may not even support locking, or make too few guarantees about it. To that end, MailDir imposes more complex naming and structural requirements than MH.

Rather than storing the files in a single directory, a MailDir MailBox uses three subdirectories: tmp, new and cur. tmp is a spool directory for new mail, used to ensure reliable delivery. Delivered, unread mail goes into the new subdirectory. As messages are read, they are moved into cur.

MailDir message naming conventions are defined so that message names are unique across shared filesystems, which means you don't get the normal set of file locking issues using most other formats. Some message flags and, depending on software, other MetaData, is encoded into the filename as well, to avoid the need to open every file all the time.

MailDir variants are used by Cyrus and courier IMAP daemons. Other MTAs have MailDir support, such as Exim and Postfix. The procmail(1) MDA also supports it, as do many MailClients such as Mutt and Evolution.

See also:

The following authors of this page have not agreed to the WlugWikiLicense. As such copyright to all content on this page is retained by the original authors.
  • StephenLewis
The following authors of this page have agreed to the WlugWikiLicense.

PHP Warning

lib/plugin/WlugLicense.php:99: Warning: Invalid argument supplied for foreach()

lib/plugin/WlugLicense.php:111: Warning: in_array() [<a href='function.in-array'>function.in-array</a>]: Wrong datatype for second argument

lib/plugin/WlugLicense.php:111: Warning: in_array() [<a href='function.in-array'>function.in-array</a>]: Wrong datatype for second argument