[Dovecot] Complete migration from Cyrus on remote server
Alan McGinlay - SICS
alanm at sics.se
Tue Dec 3 16:01:42 EET 2013
I am working on a complete migration from an old solaris machine
running Cyrus IMAP v2.3.14 and wish to migrate all users to a new
vm running Dovecot 2.0.19.
What I have so far is a fully functional dovecot installation with LDAP
/ Dovecot SASL auth using Maildir++.
My plan is to use Perdition IMAP proxy on a third host and migrate
users a few at a time (see attached picture of my whiteboard).
The proxy is in place and already used by webmail clients to connect to
the old server, shortly I will change the dns to point smtp.domain.com
and imap.domain.com etc to the proxy instead of the old server but I
haven't finished testing yet. Once that is done it is a simple matter
changing the proxy configuration per user to make them hit the new
The problem I am having with this is that I am using Imapsync
(http://imapsync.lamiral.info) to perform the initial synchronization
have scripted it to maintain sync every 10 minutes with the addtion of
"--maxage 1" option) using the following command line options:
/usr/local/bin/imapsync --noreleasecheck --useheader ALL --delete2
--expunge2 --tmpdir /var/vmail/cache --subscribe --subscribed --tls1
--tls2 --usecache --nofoldersizes --nocheckmessageexists --host1
oldserver.domain.com --authuser1 adminuser --user1 testuser at domain.com
--authmech1 PLAIN --password1 <HIDDEN> --host2 newserver.domain.com
--authuser2 adminuser --user2 testuser at domain.com --authmech2 PLAIN
All email is copied over and stored in dovecot as you would expect.
Then I switch the user to the new server on the imapproxy and restart
the client (thunderbird or whatever). This is where all email headers
are downloaded again as if they were new! There are *Many* users here
who would complain intensely if this happened and I was really wanting
the migration to be as invisible as possible.
Is there a way to do what I have described without the clients
redownloading headers / full messages?
I have been working on this for some time now but have hit a roadblock
and don't know where to turn, any help would be really appreciated!
* The proxy is not used during imapsync.
* Some users have 20 years worth of mail running into 10's of GB
* I have looked at dsync but the docs state that the mailbox should not
be accessed during sync, this is not possible for me (it doesn't say
this is the case however)
More information about the dovecot