2

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?

cappuccino
  • 259
  • 1
  • 4
  • 9

7 Answers7

6

You can use IMAPSync - http://imapsync.lamiral.info/

It works wonderfully for batch migrations...

Marco Demaio
  • 590
  • 1
  • 8
  • 23
ewwhite
  • 197,159
  • 92
  • 443
  • 809
2

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

1

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

Jon Reeves
  • 438
  • 2
  • 8
1

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.

Ben Pilbrow
  • 12,041
  • 5
  • 36
  • 57
  • Hey Rick, I used the imapcopy.pl first, however, it generates error messages and nothing is copied: http://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 06: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 07:01
1

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

HTH

Brent
  • 305
  • 2
  • 11
  • 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
0

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.

Black Hand
  • 186
  • 1
0

I used Java program imapcopy. And it beats all other ways off.

George Gaál
  • 490
  • 3
  • 8