I'm using Dovecot 1.0.1-12 on Linux/Fedora 7 along with sendmail and procmail all running on the same box mail is stored in mbox format It's a small system with a half dozen or so e-mail "accounts". Each with 40-60MB of messages in various folders. I keep seeing messages about how mbox is antiquated and anybody with more than 100 messages etc should not use mbox, but use maildir instead. I'm not entirely convinced.... there seem to be pros and cons for each. Is there a discussion somewhere that really highlights why one format is so much better than the other? The last time I tried to convert from mbox to maildir, things got pretty botched up, no data loss, but it wasn't pretty. :-) Can Dovecot handle mbox for some users and maildir for others? I'd like to try a conversion for one user... I'll probably create a new user, then have procmail copy (via ! action code) all mail for one user to that new user. Thank you
Wow this is weird because I'm about to make this same jump next week! From what I'm reading so far the big draw back with mbox is the single file with all the emails in it. When you delete a message from that file the whole file has to be rewritten without that email in it. If the box is big enough that can be a serious drag on the server. We have been using Dovecot here all school year for Imap & Pop3 with the Mbox format and when two or more people delete at the same time the utilization on my 3ware card shoots up. We bought the BBU unit for the 3ware so I could enable WRITE cache and that has helped tremendously. I thought this study in regards to speed was quite interesting: http://www.courier-mta.org/mbox-vs-maildir/ <http://www.courier-mta.org/mbox-vs-maildir/> So far my testing conversion process has gone really well. I am surprised how easy it was to tell procmail to do MailDir instead and even the conversion process was super easy. For converting the old inbox and folders I am using the tool mb2md.pl from http://batleth.sapienti-sat.org/projects/mb2md/ I was having a really hard time figuring all of this out until I ran into this webpage: http://adam.rosi-kessel.org/weblog/2007/04/18/adams-super-simple-guide-to-mbox-maildir-conversion/ I know through namespaces you can do inbox in one type and other boxes in another type. I was initially thinking about doing all new stuff in maildir and still support the old ~/mail format. The setup seemed easy enough, but I figured in the long run I am shutting down the server for a few hours to do this so I mis well go all the way. The only thing I'm not sure of is what the best file system to keep this on. I have been keeping my home directories on ReiserFS for quite a while, but one of our tech thinks XFS would be good. All data I have right now tells me to stay ReiserFS though. Even Dovecot's own page says XFS may not be a wise choice. Hope some of this stuff helps you. My server BTW is: Slackware Slamd64 11 (Added Kerberos, Dovecot, etc after the fact) Dual AMD Opteron 242s 4 Gigs RAM 800 Gig RAID 5 3G SATA array ReiserFS on /home /var/spool/mail -Jesse C. Smillie "Insert inspirational or witty comment here...." Don Russell wrote:> I'm using Dovecot 1.0.1-12 on Linux/Fedora 7 > along with sendmail and procmail all running on the same box > mail is stored in mbox format > > It's a small system with a half dozen or so e-mail "accounts". Each > with 40-60MB of messages in various folders. > > I keep seeing messages about how mbox is antiquated and anybody with > more than 100 messages etc should not use mbox, but use maildir instead. > > I'm not entirely convinced.... there seem to be pros and cons for > each. Is there a discussion somewhere that really highlights why one > format is so much better than the other? > > The last time I tried to convert from mbox to maildir, things got > pretty botched up, no data loss, but it wasn't pretty. :-) > > Can Dovecot handle mbox for some users and maildir for others? I'd > like to try a conversion for one user... I'll probably create a new > user, then have procmail copy (via ! action code) all mail for one > user to that new user. > > Thank you > > ------------------------------------------------------------- > This mail was scanned by BitDefender > For more informations please visit http://www.bitdefender.com > > > --------------------------------------------------------------------------- next part -------------- A non-text attachment was scrubbed... Name: jsmillie.vcf Type: text/x-vcard Size: 319 bytes Desc: not available URL: <http://dovecot.org/pipermail/dovecot/attachments/20070629/d6136559/attachment-0002.vcf> -------------- next part -------------- A non-text attachment was scrubbed... Name: smime.p7s Type: application/x-pkcs7-signature Size: 2505 bytes Desc: S/MIME Cryptographic Signature URL: <http://dovecot.org/pipermail/dovecot/attachments/20070629/d6136559/attachment-0002.bin>
* Jesse C. Smillie <jsmillie at gatewayk12.org>:> The only thing I'm not sure of is what the best file system to keep this > on. I have been keeping my home directories on ReiserFS for quite a > while, but one of our tech thinks XFS would be good.XFS is lousy for many small files. We tried XFS for our 9000 Users (Maildir) and swithced back to ext3.> All data I have right now tells me to stay ReiserFS though. Even > Dovecot's own page says XFS may not be a wise choice.My experience tells me to stay away from ReiserFS as well. -- Ralf Hildebrandt (Ralf.Hildebrandt at charite.de) plonk at charite.de Postfix - Einrichtung, Betrieb und Wartung Tel. +49 (0)30-450 570-155 http://www.arschkrebs.de Unix is the answer, but only if you phrase the question very carefully.
On Fri, 29 Jun 2007 10:14:42 -0700 Don Russell <russell.don at gmail.com> wrote:> Can Dovecot handle mbox for some users and maildir for others?Yes, if you don't have the mail_location variable set, then Dovecot will look in ~/Maildir /var/mail/username ~/mail ~/Mail in that order. See http://wiki.dovecot.org/MailLocation j
FWIW, I used imapsync for the data migrations of a) an old sendmail server with mbox format to a new server running postfix+dovecot, and b) and old and busted Microsoft SBS2000 Exchange instance to a new server running postfix+dovecot. Worked well in both cases, and the process left the original servers intact in case the migration hadn't gone as well. Completely unscientific observation, but the Maildir format seems quite responsive in the common email pattern of open the inbox, fetch the message headers, let the filter process spam, finally read ham messages. That has a lot to do with Dovecot's speed, of course.
Don Russell wrote:> I'm using Dovecot 1.0.1-12 on Linux/Fedora 7 > along with sendmail and procmail all running on the same box > mail is stored in mbox format > > It's a small system with a half dozen or so e-mail "accounts". Each with > 40-60MB of messages in various folders. > > I keep seeing messages about how mbox is antiquated and anybody with > more than 100 messages etc should not use mbox, but use maildir instead. > > I'm not entirely convinced.... there seem to be pros and cons for each. > Is there a discussion somewhere that really highlights why one format is > so much better than the other?One factor not often discussed: When I switched from mbox to maildir the size of incremental backups went down to a fraction of its previous size (only the new messages are backed up, not the entire mailbox). It allowed me to do incremental backups to disk instead of tape, which I still use for full backups. P.S. consider maildrop instead of procmail if you switch to maildir. See info in the dovecot wiki. Mark
Don Russell wrote:> I'm using Dovecot 1.0.1-12 on Linux/Fedora 7 > along with sendmail and procmail all running on the same box > mail is stored in mbox format > > It's a small system with a half dozen or so e-mail "accounts". Each > with 40-60MB of messages in various folders. > > I keep seeing messages about how mbox is antiquated and anybody with > more than 100 messages etc should not use mbox, but use maildir instead. > > I'm not entirely convinced.... there seem to be pros and cons for > each. Is there a discussion somewhere that really highlights why one > format is so much better than the other?mbox is broken by design. Look at the next line. From what I can tell, mbox will convert the first word of this line to ">From". This means the message is modified, which is ok for raw text, but is not ok for structure text such as TeX or XML. I've also had to edit mbox files with via to remove garbage, probably caused by lock issues. Regarding performances: while a single file should be faster to parse than loading N files, how about: - moving messages between folders (including folders for different accounts) - rsync-like backup is simple and fast with maildir - using messages to retrain a spam filter ("mv" is all that is needed!).> > The last time I tried to convert from mbox to maildir, things got > pretty botched up, no data loss, but it wasn't pretty. :-)just because you got it wrong doesn't make it's hard. you probably didn't take enough time to get it right.> > Can Dovecot handle mbox for some users and maildir for others? I'd > like to try a conversion for one user... I'll probably create a new > user, then have procmail copy (via ! action code) all mail for one > user to that new user.Why not use one of the available mbox 2 maildir utilities.
> The upcoming dbox and cydir formats of course beat everything in > performance :)Is dbox in Dovecot 1.1 tree now? Is it the redesigned dbox? How close is dbox ready for general use? I am interested in testing it out. Where can I find instruction on how to configure dovecot to use dbox? Simon
Don Russell wrote:> I'm using Dovecot 1.0.1-12 on Linux/Fedora 7 > along with sendmail and procmail all running on the same box > mail is stored in mbox format >[snip] Thanks to all who replied. This seems to have sparked quite a discussion, and given me quite a bit to read/look into. Sounds like dbox is worth waiting for. I'd I'm going to convert from mbox, I'd rather convert once. :-)