Move email to new server

3 posts / 0 new
Last post
#1 Wed, 06/10/2009 - 04:36
Dim Git

Move email to new server

One last request, I hope.

I need to move the contents from an old mailbox on another server (not virtualmin) where the mail is stored in mbox format to this server (with Virtaulmin) where the mail is stored in the users space.

Does anybody know of a sensible way to do that.

Thanks for reading.

Wed, 06/10/2009 - 08:10
jahlewis

I asked this several weeks ago, and this is the command (which you run as root):

virtualmin copy-mailbox --source /var/spool/mail/username --dest ~username/Maildir/

if your user has saved email "folders", then the above script would work as well, but with the additional folders in the user's mail directory

virtualmin copy-mailbox --source ~username/mail/filename t --dest ~$CLIENT/Maildir/filename/

The above works for me from the command line, but I can't get it to work in a bash shell script to do multiple accounts/folders... (http://www.virtualmin.com/node/9846)

Wed, 06/10/2009 - 11:13
Dim Git

That is well wicked !

Thanks for the post.

Thanks Jamie for a brilliant tool !

I feel so much better that something is going right for a change. :o)

Topic locked