Re: Manual Backup & Restore Procedures

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Peter,

This is a very open-ended question. You'll have to make a number of decisions on what you require and what resources you want to use to meet those requirements. This information is not specific to Cyrus-IMAP, which may explain no one else responding yet. It is the same no matter what the actual data on the filesystem(s) involved really is.

For starters, you have to determine what your backup and recovery process is aimed to achieve: is reverting to last night's backup sufficient or do you require that no email can ever get lost.

For a "last night's backup" environment, you then have to determine if the amount of time you can offline the cyrus processes  to copy the configdirectory and data partitions is sufficient to make the backup. Regardless of the type of environment, I generally opt for putting the data on filesystems that allow for a snapshot. That way you can script stopping cyrus, creating the snapshot(s) and restarting cyrus, all in fairly quick succession.

Once you've stopped cyrus, you can use whatever os tool for backup that you'd normally use: dd, tar, rsync, rclone, btrfs send/receive, etc. They all do the same in the end, give you a copy of the filesystem(s) involved. If you have snapshots at your disposal, though, you can get Cyrus processes back online while you then stream the snapshot image off to whatever your backup destination(s) might be.

I would create a second server or virtual machine with access to sufficient storage to duplicate the Cyrus-IMAP server. Restore the backup data within the virtual machine each cycle and you only have to start Cyrus on the secondary server and point the clients to it while you repair your original server.

If you don't have a long enough window of time to perform you backup,  you can use the second server as a replicated Cyrus server instead. Start here for replicating: https://www.cyrusimap.org/imap/reference/architecture.html#replication. You can then start and stop Cyrus on the secondary server at will in order to make backups of the data.

If you need to guarantee that no email is every lost, you should again be looking at Cyrus replication.

There are many ways to acheive recovery after a failure. They all require different resources and only you can determine which of the many choices is the best fit for your needs.

I hope this helps get you started. My utilization of Cyrus-IMAP is just for a vanity domain so I've not implemented Cyrus replication or Murder configurations. I have a lifetime of experience developing and maintaining database servers and programming languages to fall back upon. Since you gave no indication on the number of users, size of the data store or required operational hours for accessing Cyrus-IMAP, it's hard to give you much more than generic advice.

Best regards,
Eric

[Index of Archives]     [Cyrus SASL]     [Squirrel Mail]     [Asterisk PBX]     [Video For Linux]     [Photo]     [Yosemite News]     [gtk]     [KDE]     [Gimp on Windows]     [Steve's Art]

  Powered by Linux