[Dovecot] Maildirs location migration

Thomas Hummel hummel at pasteur.fr
Wed Apr 3 18:42:20 EEST 2013


Hello Timo,

I'm using dovecot-2.1.15 with Maildir mailboxes located on an NFS filer.
Postfix is used to deliver mail through procmail ("mailbox_command) as LDA.

Our team has bought another filer and everything is meant to go on it, so we're
planning to migrate those mailboxes to the new filer.

To test it only on a subset of users, I ended up to the following solution :


 1. keep new messages in postfix mailqueue for those users (via a service and a transport)
 2. prevent new dovecot authentication for those users (via the "auth-deny"
    passwd-file type passdb)
 3. doveadm kick those users
 4. copy or rsync the mailboxes
 5. symlink maildir, control and indexes directories to the new filer (nfs
    mounted on the mail server)
 6. re-enable mail delivery and imap authentication


I was wondering if such a migration could be done differently in order to be
seamless to the user :

- for the postfix part, it would be easy, I guess, to create a new service (and
  a new transport map using this service) to deliver to the new location

- but for the imap part, I'm not sure if it can be done. My guess is that, if
  feasible, it would involve some namespace settings and a dsync copy but I
  cannot figure out how exactly.

What do you think ?

Thanks

-- 
Thomas Hummel 	    | Institut Pasteur
<hummel at pasteur.fr> | Groupe Exploitation et Infrastructure


More information about the dovecot mailing list