[Web-cyradm] Moving to another server

George Kontostanos gkontos.mail at gmail.com
Mon Jul 9 17:50:25 CEST 2007


Hi Sruart and thanks for your valuable info.
So far I have managed to reconstruct almost everything except for the
actual emails that are stored on the old server. Odd think I noticed
that in the old server the mail directory had a structure of /mail/ a
b c .. whereas the new doesn't. I'm looking into it.
In any case the old mail server is still production has 17G hard disk
space and 84% disk usage. (yes one partition) So, I'm moving with
careful steps here.

Thanks again.

George

On 7/9/07, Stuart Murray-Smith <eight32 at gmail.com> wrote:
> Hi George
>
> > Do you mean the log files of the new server ?
>
> Apologies, I think I misread your original post.
>
> > Btw. In the old server I have:
> > ls /var/lib/cyrus
> > drwxr-x---   11 cyrus    mail         4.0K Jul  9 09:38 .
> > drwxr-xr-x   23 root     root         4.0K Dec 24  2004 ..
> > drwx------    2 cyrus    mail         4.0K Jul  7 15:38 db
> > drwx------    2 cyrus    mail         4.0K Jul  9 09:38 db.backup1
> > drwx------    2 cyrus    mail         4.0K Jul  9 09:08 db.backup2
> > -rw-------    1 cyrus    mail          18M Jul  9 09:38 deliver.db
> > drwx------    2 cyrus    mail         4.0K May 11  2004 log
> > -rw-------    1 cyrus    mail         209K Jul  5 16:07 mailboxes.db
> > drwx------    2 cyrus    mail         4.0K May 11  2004 msg
> > drwx------    2 cyrus    mail         4.0K Jul  9 09:43 proc
> > drwx------   28 cyrus    mail         4.0K May 11  2004 quota
> > drwxr-x---    2 cyrus    mail         4.0K May 12  2004 socket
> > -rw-------    1 cyrus    mail         8.0K May 12  2004 tls_sessions.db
> > drwx------   28 cyrus    mail         4.0K May 11  2004 user
> >
> > Any idea on how to move those to the new server? I suspect that the problem
> > is here.
>
> Yes, I asked the list this question about 10 months ago. Here are some
> of the replies I received:
>
> =====8<-------
>
> Create the mailbox, copy the 4GB into it, remove all cyrus.* files and
> run reconstruct (as user cyrus) and the quota (as user cyrus).
>
> =====8<-------
>
> Take a look to: "imapsync"
>
> =====8<-------
>
> A brief summary below is about backup restore procedures:
>
> 1) Make a dump of all mailboxes to the text file:
>
> su - cyrus -c "ctl_mboxlist -d" > /var/lib/imap/mailboxlist.txt
>
> And restore it with:
>
> su - cyrus -c "ctl_mboxlist -u" < /var/lib/imap/mailboxlist.txt
>
> 2) Make a regular backups (in my case with DSM client) of
> /var/spool/imap/ and /var/lib/imap/, without stopping cyrus, in this
> case I endanger myself in some data inconsistency and maybe some
> e-mails lost (which were in process while backup was running).
>
> 3) In case of disaster I can just copy mail directly from the backup
> to the mail store directory (/var/spool/imap/user/%username%),
> And run:
> /usr/lib/cyrus/bin/reconstruct -rf user/username
>
>
> 4) All quotas (in /var/lib/imap/quota/%firstletter of username%/)will
> not be reconstructed, so I'll need to do it manually.
>
> 5) All subscription and seen info (in /var/lib/imap/user/%firstletter
> of username%/) will not be reconstructed, but I could restore it from
> the regular backup.
>
> =====8<-------
>
> rdiff-backup
>
> =====8<-------
>
> I've used most recommendations above for various other requirements to
> a high degree of success :-)
>
> Please let us know how it goes.
>
> Have a great day!
>
> Regards,
>
> Stu@
> _______________________________________________
> This mailing list is hosted and supported
> by bit-heads GmbH | http://www.bit-heads.ch
>
> _______________________________________________
> Web-cyradm mailing list
> Web-cyradm at web-cyradm.org
> http://www.web-cyradm.org/mailman/listinfo/web-cyradm
>


More information about the Web-cyradm mailing list