I'm trying to copy of IMAP emails from one server to my new server but after Googling for hours and trying several tools, nothing is working. Is there a tool that actually works?

I am copying hundreds of thousands of emails so using a email client is out of the question, I tried it, and at the rate of a email per 2 seconds, it would take a few weeks or months!

www.linux-france.org/prj/imapsync/ is commonly mentioned, however, the tool is no longer available.

I tried www.athensfbc.com/imap_tools/ which just hangs and does nothing.

Any migration tools that work?

link|improve this question

33% accept rate
feedback

6 Answers

up vote 0 down vote accepted

I think I might have gotten it to work [...] used the imapsync.pl tool instead

I see what the problem is. There is a bug in imapcopy.pl that comes into play when the source and destination mailbox hierarchy prefixes are both "Inbox.". I have fixed it and posted the new version at http://www.athensfbc.com/imap-tools.

imapsync.pl does not have that problem.

-Rick

link|improve this answer
feedback

You can use IMAPSync - http://freshmeat.net/projects/imapsync/

It works wonderfully for batch migrations...

link|improve this answer
feedback

I tried www.athensfbc.com/imap_tools/ which just hangs and does nothing.

I'm the author of those tools. I assume you ran imapcopy.pl?

Try running it in debug mode with the -d and -I arguments and please update your original question with the results. That will hopefully give an indication of why it is hanging.

link|improve this answer
Hey Rick, I used the imapcopy.pl first, however, it generates error messages and nothing is copied: snipt.org/xggO, I tried to use the imapsync.pl tool, but it freezes and takes 100% of the CPU and produces no debug messages. – cappuccino Apr 15 '11 at 6:44
I think I might have gotten it to work, i deleted my destination IMAP account, recreated it, created all the folders from source manually and used the imapsync.pl tool instead – cappuccino Apr 15 '11 at 7:01
feedback

If you are using Maildir, theres no reason why you cant just scp them.

HTH

link|improve this answer
More to the point, if you are not changing mailbox formats, scp will be much faster for all file based formats. – Jeff Strunk Apr 15 '11 at 21:26
feedback

I have heard good things about offline IMAP (http://offlineimap.org/) Not personally used it, but I know someone that has and he was very pleased with it

link|improve this answer
feedback

if you are using the same imap backend, and rsync with compression (-avzr) maintaining permisions/dates is your best option.

if you are copying using the imap protocol because are changing imap backend:

my strategy:

i use Imapcopy (http://home.arcor.de/armin.diehl/imapcopy/imapcopy.html) for this process, with this tool i need a text file with user/passwords and folders to exclude from copy

i generate 10 files for imapcopy, to paralelize the copy operation via IMAP, and launch the files.

i did migrate from/to ms-exchange/dovecot/courier/cyrus for years with this procedure without problems (btw my preferable destination imap backend, cyrus)

i only did have problems with older Lotus Domino versions, this one serialize their IMAP operations and the procedure don't work.

link|improve this answer
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.