courier 0.63 to Dovecot migration

ssgill

Verified User
Joined
May 9, 2012
Messages
164
Hello, i have a mail server running courier 0.63 with the maildir structure

.maildir
--.Bugzilla
--.Somefolder

and Dovecot structure
Maildir
--cur
-- new
-- subscriptions
-- tmp
-- dovecot.index.cache dovecot.index.log dovecot.mailbox.log dovecot-uidlist dovecot-uidvalidity dovecot-uidvalidity.4fe0c1d4

Now i would like to move the mail from existing server to new server. I did read the instructions @ this page http://wiki.dovecot.org/Migration/Courier and according to this i can run the script to preserving IMAP UIDs and POP3 UIDLs. But could someone please detail the steps i need to follow a successful migration.

1) change in dovecot config file for handling .Somefolder
2) So technically can i zip the content of current mail folder after running the said script and expand in Maildir in new server.
3) Do i need to reset file permissions in new server.

Anything else that needs to be taken care of, Thanks.
 
Are you moving to a DirectAdmin based server, or are you asking in the wrong place?

Either way, I'm guessing that this is too specialized a request to find anyone here who's done it. I'd hesitate to blindly follow instructions on a dovecot wiki unless the wiki was specifically written for conversion to DirectAdmin, because DirectAdmin's handling of virtual mailboxes may be quite different from the generic ones.

I'd strongly suggest that after setting up the users on your DirectAdmin server (or any Dovecot-based server) you just figure out how to send the emails to the same addresses on the new server, and let Dovecot put everything into the proper mailboxes, which will be set up as the mail arrives.

I or others can offer this migration as a service; I have no idea what it would cost. I suppose I could create a how-to as well, but to guarantee it I'd need to create it while doing it, so it would cost as much as doing it for you, or perhaps even more.

Jeff
 
Thanks for your reply, i did a test run by moving one mail account from old server running courier. Just zipped the folders, created new account on the directadmin server running dovecot. Uploaded, unzipped the folders in mail account created. Fixed the permissions with

./set_permissions.sh maildir <account> <path/to/Maildir>

All the permissions looked good, then ran the Migration script

./courier-dovecot-migrate.pl --to-dovecot --convert --recursive <path/to/Maildir>

At this point no errors, so added new account to Thunderbird. It downloaded all the mail, folders looked good, all mail status looked good eg: unread mail came up as unread and read was marked read. So all looks well only issue was that user created folders show up on the same level as INBOX. So just to test i created a new folder and that was created with inbox as prefix. So new folders are created as

.INBOX.test

as to just .test. Meaning all the folders should fall under INBOX without adding .INBOX prefix.

Any ideas how to configure dovecot to handle this. Thanks
 
How are you creating folders? Using IMAP? I've turned to Squirrelmail to create serverside folders: Squirrelmail let's you chose the base directory, including none.

I don't know if Thunderbird will let you do it or not; I use Kmail, and if there's a way to do it, I haven't found it.

I've only been playing with IMAP for the past week, and so I have little experience with it as of yet.

Jeff
 
At this point no errors, so added new account to Thunderbird. It downloaded all the mail, folders looked good, all mail status looked good eg: unread mail came up as unread and read was marked read. So all looks well only issue was that user created folders show up on the same level as INBOX. So just to test i created a new folder and that was created with inbox as prefix. So new folders are created as

.INBOX.test

as to just .test. Meaning all the folders should fall under INBOX without adding .INBOX prefix.

Any ideas how to configure dovecot to handle this. Thanks

Try adding this to your dovecot.conf:

Code:
namespace {
  inbox = yes
  location =
  prefix = INBOX.
  separator = .
  type = private
}
That is what I needed to do to make the email appear exactly like it did in before. The clients would still be required to add INBOX. as a name prefix in their clients, so that the folders don't appear as sub-folders of INBOX.
 
Back
Top