# ACTION: Backup Scalix # # WARNING: # In order to guarantee Scalix database integrity, Scalix backups # must be made from an offline copy of the data. This is because a # change to the database is generally made by modifying multiple files # simultaneously. If, during a backup, one of these files is modified # after it is backed up, but the others are modified before they are # backed up, than the backup will be corrupt. The options for backing # up are therefore: # 1. Shut down Scalix, back up, Restart # Advant: Backup not corrupt. Simple. Always works # DisAdv: System will be unavailable during backup. # 2. Use advanced filesystem such as ReiserFS, XFS, or Veritas # to make a "snapshot" filesystem. A snapshot filesystem holds # the changes made since the backup started, and allows the # backup program to access a "snapshot" of the system at the # time the backup started. # Advant: Backup not corrupt. No downtime. # Disadv: Requires advanced FS. Requires approximately extra # 10% diskspace to hold snapshot information. # 3. Backup Scalix online from online data set. The restore # procedure will need to include commands to uncorrupt the # database. Those commands take time to run. This generally # works, but it is not guaranteed to work and is "unsupported". # The command to uncorrupt a database is omscan(8). # Advant: No downtime. Simple. # Disadv: Lengthy, unreliable restore. Unsupported. # # This backup script does option #1, shut down to backup, so that # it will work even if you do not have an advanced filesystem. If # you do have an advanced filesystem, comment out the default backup # script and modify the steps below to build a backup script based # on a snapshot filesystem. # # This sample backup script does a full backup of Scalix data in # /var/opt/Scalix, and it uses tar. Scalix does not care if you # do full or partials, if you backup /, or which backup program you use. # However, please take note of the WARNING above. # # Standard backup script: # /opt/Scalix/bin/omshut 2>&1 >> $MAINTLOG tar -cf $BACKUP_DEVICE /var/opt/Scalix 2>&1 >> $MAINTLOG /opt/Scalix/bin/omrc 2>&1 >> $MAINTLOG