1

Topic: how to migrate old mail server to iredmail new server

==== Provide basic information to help troubleshoot ====

Old server
- centos 5.5 64 bit
- sendmail, dovecot, spamassin , clamav ,amavisd, OpenWebMail
- mail users created using bellow script
        sudo groupadd user1
        sudo useradd -c "Full name" -s /sbin/nologin -g user1 -G mail -m user1
        sudo passwd user1

- mail directory --> /var/spool/mail
       all inbox mail of a one user ,saved on a single file in /var/spool/mail


New server
- iRedMail-0.7.3: open source edition
- centos 6

i could transfer all users successfully. but no idea how to transfer inbox mails to new one .

in iredmail , there are separate files in  /var/vmail/vmail1/domail-name/maildir/cur/user1

but in the old server , there is a single file /var/spool/mail/user1

please , help me to solve this problem...........

----

Spider Email Archiver: On-Premises, lightweight email archiving software developed by iRedMail team. Supports Amazon S3 compatible storage and custom branding.

2

Re: how to migrate old mail server to iredmail new server

asanka wrote:

i could transfer all users successfully. but no idea how to transfer inbox mails to new one .

Mailboxes on old server are mbox format, you have to convert them to Maildir format first, then copy to correct location on new server.

asanka wrote:

in iredmail , there are separate files in  /var/vmail/vmail1/domail-name/maildir/cur/user1

It's /var/vmail/vmail1/domain-name/u/s/e/user-[TIMESTAMP]/cur/.

asanka wrote:

but in the old server , there is a single file /var/spool/mail/user1

Convert this file to Maildir format, then copy converted files into /var/vmail/vmail1/domain-name/u/s/e/user-[TIMESTAMP]/cur/.

3

Re: how to migrate old mail server to iredmail new server

Hi,

I assume /var/vmail/vmail1/domain-name/u/s/e/user-[TIMESTAMP]/cur/ get created only after a webmail/IMAP session. in that case is there any way all users Maildir created automatically and any script available to convert all users mbox into maildir and copy all users maildir to rexpective folder??

Thanx in advance..

Im in a process of migrating 5k+ users from sendmail to postfix flavor and much inspired by the support and the solution provided by iredmail.. Really going forward to buy iredmailpro soon...

4

Re: how to migrate old mail server to iredmail new server

shamjith wrote:

I assume /var/vmail/vmail1/domain-name/u/s/e/user-[TIMESTAMP]/cur/ get created only after a webmail/IMAP session. in that case is there any way all users Maildir created automatically and any script available to convert all users mbox into maildir and copy all users maildir to rexpective folder??

User maildir is /var/vmail/vmail1/domain-name/u/s/e/user-[TIMESTAMP]/Maildir/, this maildir path is stored in MySQL/LDAP without the suffix "Maildir/", "Maildir/" will be appended by Dovecot.

Maildir is just some general directories, you can create them manually.
Reference: http://qmail.org/man/man5/maildir.html

You can find many tools to convert mbox to Maildir with Google.
Reference: http://wiki.dovecot.org/Migration/MailFormat