Jeremy’s World

Jeremy de Oliveira-Kumar’s website about interesting stuff

Entries Comments



Cryus Mail server back-up script

25 April, 2008 (21:15) | E-mail, Linux, Shell Scripts | By: Jeremy

During my early days mucking around with linux in attempt to find the best pieces of software for a range of different tasks, I stumbled upon cyrus mail server, the Carnegie Mellon Unversity’s implementation of an IMAP server.

Having already tested the Washington University implementation of IMAP as well as Dovecot, I was still unconvinced by the IMAP protocol, particularly its implementation on UNIX-based systems.  Cyrus changed this point-of-view significantly.  With a closed database, capable of easily interfacing with SMTP servers such as postfix and sendmail, cyrus proved to be a robust system and with the latest versions including the possibility of scaling and distribution, it was for a long time Excel Building Management’s choice mail server.

The only problem was that the facilities for backing up a cyrus server were almost non-existent.  The only script/software I could find that even came close was mailbfr.  Unfortunately, the script was written for Mac OS servers and therefore needed some tuning and tweaking to port to a Linux flavoured system.  Thus, my programming skills came to the rescue and cyrus-backup was born.

Cyrus-backup is a simple port of an earlier version of mailbfr to the linux environment.  Although not capable of a hot backup, it is still extremely efficient at providing a full backup of an entire cyrus database including the possibility of storing users’ filtering rules.

Cyrus-backup has saved me on more than one occassion from near disaster and running it with a cron-script once a day at 2am made my life of mail server management a dream.

So now, I am providing a copy of the script, optimised for Ubuntu (but easily customisable) to all those who use cyrus servers as a solid method of providing backup.  The script is quite self-explanatory so I have not provided documentation at this stage, although if I do make changes in the future, this may be included.

You can find a copy of the script on the linux scripts download page.

Linux Scripts

25 April, 2008 (21:06) | News | By: Jeremy

On this page I have provided a collection of primarily shell scripts freely available for those who wish to use them.  If you wish to make modifications to these scripts please let me know - I would be interested in your ideas to improve or change the way these scripts work.

Backup Scripts

http://www.eremyjay.com/wp-content/plugins/downloads-manager/img/icons/default.gif cyrus-backup.sh (20.85KB)
added: 24/04/2008
clicks: 24
Cyrus-Backup is a script for use on unix-based operating systems to help backup a cryrus mail server database. It performs offline backups of cyrus data and provides a host of parameters for setting how you wish to perform a backup. Based on mailbfr, a script specific to os x servers, this version has been customised to work on Ubuntu linux, but can easily be altered via the list of parameters for alternate flavours of linux and unix-based systems.

http://www.eremyjay.com/wp-content/plugins/downloads-manager/img/icons/default.gif mysql-backup.sh (938B)
added: 24/04/2008
clicks: 14
This is a special script to backup your entire mysql dbms. It performs a hot backup of all databases to a location specified in the script arguments. This script is useful for those administrators who need a regular backup of their dbms. Note that the mysql admin tools should be installed on the operating system (normally provided with mysql).