Converting from mbox to maildir: Difference between revisions
No edit summary |
No edit summary |
||
Line 43: | Line 43: | ||
If you get dotlock time errors, make sure all the machines are running ntp. | If you get dotlock time errors, make sure all the machines are running ntp. | ||
It could be that the existing user allready has folders in their setup because they've been using squirrelmail. This will give errors during the conversion of the type | It could be that the existing user allready has folders in their setup because they've been using squirrelmail or imap or sometihng. This will give errors during the conversion of the type: | ||
<pre> | |||
dsync(razor): Error: Can't rename mailbox INBOX to INBOX_13cabe1b5cfff750fa080000ba1da2b1: Renaming INBOX isn't supported. | |||
dsync(razor): Error: Can't rename mailbox INBOX_e72e0e3ad3f4ff5019600000ba1da2b1 to INBOX: Target mailbox already exists | |||
</pre> | |||
http://batleth.sapienti-sat.org/projects/mb2md/ | http://batleth.sapienti-sat.org/projects/mb2md/ |
Revision as of 14:45, 23 January 2013
converting from mbox to maildir for imap
problem: mbox format doesn't allow subfolders in imap.
mbox is a mailfile in /var/mail/ and maildir is 1 file per email in the users homedir/Maildir
Steps:
- replace popa3d with dovecot-pop3d
change protocols in dovecot
http://www.debiantutorials.com/installing-dovecot-imap-and-pop-daemon-with-mysql-backend/
- Get postfix to deliver in maildir format
postconf -e "home_mailbox = Maildir/"
postconf -e "mailbox_command ="
http://wiki.debian.org/Postfix#Maildir
- change the way procmail delivers mail
DEFAULT="$HOME/Maildir/"
MAILDIR="$HOME/Maildir/"
http://wiki.dovecot.org/procmail (with more options for faster delivery)
- change the way dovecot-pop3d picks up mail
- convert the mbox mailboxes to maildir format:
This converts mboxes to maildirs per user
http://wiki.dovecot.org/Migration/MailFormat
dsync -u red mirror mbox:~/mail:INBOX=/var/mail/red
If you get dotlock time errors, make sure all the machines are running ntp.
It could be that the existing user allready has folders in their setup because they've been using squirrelmail or imap or sometihng. This will give errors during the conversion of the type:
dsync(razor): Error: Can't rename mailbox INBOX to INBOX_13cabe1b5cfff750fa080000ba1da2b1: Renaming INBOX isn't supported. dsync(razor): Error: Can't rename mailbox INBOX_e72e0e3ad3f4ff5019600000ba1da2b1 to INBOX: Target mailbox already exists
http://batleth.sapienti-sat.org/projects/mb2md/
But Dovecot1 has its' own system, which Dovecot2 doesn't:
http://wiki.dovecot.org/Plugins/Convert <- NB also see alternative formats underneath page