This documentation is for Dovecot v2.x, see wiki1 for v1.x documentation.
Differences between revisions 4 and 5
Revision 4 as of 2007-05-23 13:33:56
Size: 972
Editor: TimoSirainen
Comment:
Revision 5 as of 2007-11-24 16:17:32
Size: 2096
Editor: TimoSirainen
Comment:
Deletions are marked like this. Additions are marked like this.
Line 1: Line 1:
## page was renamed from MailFormat/dbox
Line 4: Line 3:
Introduced with Dovecot 1.0a4. The point is to have a high performance mail store combining all the best qualities of other mailbox formats. Some behavior can't be universally accepted as optimal, so dbox allows sysadmin to configure those: dbox is Dovecot's own high-performance mailbox format. The original version was introduced in v1.0 alpha4, but since then it has been completely redesigned in v1.1 series.
Line 6: Line 5:
 * One mail per file, or multiple mails per file? If multiple,
  * How large each file can grow? This is a tradeoff between read and expunge performance.
  * How old files do we still append new mails to? Helps with incremental backups.
 * How often should changed mail metadata (flags and keywords) be written to dbox files, instead of only in Dovecot's index files? This is a tradeoff between reliability and performance.
dbox can be used in two ways:
Line 11: Line 7:
dbox format isn't finished yet, so it should only be used for testing purposes.  1. One message per file, similar to [:MailboxFormat/Maildir:Maildir].
 1. Multiple messages per file, but unlike [:MailboxFormat/mbox:mbox] multiple files per mailbox. (This isn't currently fully working.)
Line 13: Line 10:
== References == One of the main reasons for dbox's high performance is that it uses Dovecot's index files as the primary storage for message flags and keywords. They're still backed up to the dbox files once in a while though. Using index files as the primary storage also means that the indexes don't have to be "synchronized". Dovecot trusts that they're always up-to-date (unless it sees that something is clearly broken).
Line 15: Line 12:
 * http://dovecot.org/pipermail/dovecot/2005-September/009294.html
 * Redesign plans: http://dovecot.org/list/dovecot/2007-May/022602.html
Unlike Maildir the message file names don't change. This makes it possible to support storing files in multiple directories or mount points. dbox supports looking up files from "altpath" if they're not found from the primary path. This means that it's possible to move older mails that are rarely accessed to cheaper (slower) storage.

dbox supports a quick migration from Maildir format. It basically works by renaming Maildir/cur/ directory as the dbox's mail directory and then moving files from Maildir/new/ directory and Dovecot's control and index files there as well. The maildir files are sometimes later then converted to actual dbox files when their message flag changes are decided to be backed up (if there are no changes, they're never converted currently).

dbox storage is extensible, so in future there will be other extensions. Some things that are planned:

 * Single instance attachment storage. If multiple mailboxes/users have the same attachment, it's stored only once in disk.
 * Multiple mailboxes in one dbox storage. This makes copying messages from one mailbox to another a simple metadata update.

Multiple messages per file mode isn't currently fully functional, so it can't be enabled without modifying sources.

dbox

dbox is Dovecot's own high-performance mailbox format. The original version was introduced in v1.0 alpha4, but since then it has been completely redesigned in v1.1 series.

dbox can be used in two ways:

  1. One message per file, similar to [:MailboxFormat/Maildir:Maildir].

  2. Multiple messages per file, but unlike [:MailboxFormat/mbox:mbox] multiple files per mailbox. (This isn't currently fully working.)

One of the main reasons for dbox's high performance is that it uses Dovecot's index files as the primary storage for message flags and keywords. They're still backed up to the dbox files once in a while though. Using index files as the primary storage also means that the indexes don't have to be "synchronized". Dovecot trusts that they're always up-to-date (unless it sees that something is clearly broken).

Unlike Maildir the message file names don't change. This makes it possible to support storing files in multiple directories or mount points. dbox supports looking up files from "altpath" if they're not found from the primary path. This means that it's possible to move older mails that are rarely accessed to cheaper (slower) storage.

dbox supports a quick migration from Maildir format. It basically works by renaming Maildir/cur/ directory as the dbox's mail directory and then moving files from Maildir/new/ directory and Dovecot's control and index files there as well. The maildir files are sometimes later then converted to actual dbox files when their message flag changes are decided to be backed up (if there are no changes, they're never converted currently).

dbox storage is extensible, so in future there will be other extensions. Some things that are planned:

  • Single instance attachment storage. If multiple mailboxes/users have the same attachment, it's stored only once in disk.
  • Multiple mailboxes in one dbox storage. This makes copying messages from one mailbox to another a simple metadata update.

Multiple messages per file mode isn't currently fully functional, so it can't be enabled without modifying sources.

None: MailboxFormat/dbox (last edited 2015-03-20 11:12:33 by TimoSirainen)