Backup of Cyrus
asiani at wanadoo.fr
asiani at wanadoo.fr
Mon Dec 15 02:52:44 EST 2003
If someone have a solution to have a backup of cyrus...please post it on the
list !!!!
I have the same problem, how can i backup without stopping the mail
server...
alain
-----Message d'origine-----
De : owner-info-cyrus at lists.andrew.cmu.edu
[mailto:owner-info-cyrus at lists.andrew.cmu.edu]De la part de Craig Ringer
Envoye : vendredi 12 decembre 2003 18:01
A : Doug Koobs
Cc : info-cyrus at lists.andrew.cmu.edu
Objet : Re: Backup of Cyrus
Doug Koobs wrote:
> I've been doing some reading of the list archives, and have learned that
my
> current backup process is not sufficient. I'm hoping to get some feedback
on
> my new proposed process. I only have about 20 users, total mail store is
> under 300 MB. I can stop the services. I want to be able to recover from
> total disaster, and from user errors. For now, I will do a full backup
> nightly
>
> I'm using RH9 and Simon Matter's RPMs. Here are the beginnings of a script
> that I hope to use:
>
> #######################################
> postfix stop # Stop MTA
> etc/rc.d/init.d/cyrus-imapd stop # Stop Cyrus
> su cyrus -c "ctl_mboxlist -d" > mailboxes-`date '+%m%d%y'` # List
mailboxes;
> #file makes restore easier???
It's not quite as critical as I originally thought (as the ACL
information _is_ stored somewhere else as well), but it can make
recovery from db corruption easier, and can make restoring to a
different machine a _lot_ less fuss. That said, I think Simon Matter's
RPM builds take care of making these backups for you anyway. According
to a recent post by Simon it makes backups in /var/lib/imap/backups - so
verify that they're there and look right, and you should be fine.
> #Backup the following directories (I haven't decided on which tool yet):
> #/var/spool/imap
> #/var/lib/imap
>
> etc/rc.d/init.d/cyrus-imapd start # Start Cyrus
> postfix start #Start MTA
> ########################################
>
> Will this be sufficient? Thanks,
It's pretty similar to what I do. Though I use snapshots instead of
stopping the daemons, I'd /prefer/ to be able to just stop the daemons.
Unfortunately, my mail spools are growing - fast - and I have users who
keep weird hours (not least myself). At last check the gzipped backup
files were 3gb, from mail spools of 4.6GB. This would mean too much
downtime if I stopped the daemons, especially since I'm doing network
backups to (slow) tape.
IMHO the best way to make sure your backups are OK is to restore them.
Preferably to a test machine ;-) - ideally the one you'd be restoring to
if there was a hardware failure right now (and maybe another, different,
one as well). Alas, you're proabably in a situation like me - "what cold
spare?!?" - where this isn't possible. I did my restore testing on a
hapless debian 3.0 box - and this is why I'm so paranoid about
converting the mailboxes.db . Everything else about the restore went
perfectly, but it couldn't use the mailboxes.db because of a different
berkley db version. I'm very glad I learned that then, and not after a
server failure.
Craig Ringer
More information about the Info-cyrus
mailing list