SARK V4.0.0 Backup

From sailpbx
Revision as of 07:52, 19 April 2013 by Adminwiki (talk | contribs) (Backup)
Jump to: navigation, search

back to SARK v4.0.0 contents

Backup

All of SARK's PBX entities are kept on a single SQL database file which is easy to backup and restore. SARK has 2 kinds of backup called backups and snapshots. By default, a backup will be taken every night with the last 9 copies being kept. A snapshot is taken every time you issue a commit with the last 9 copies kept. You can click on the download icon of any backup or snapshot to download it to your desktop. The backups and snapshots themselves can be found in /opt/sark/snap and /opt/sark/bkup so you can easily write a cron job to offload them to other systems or media for safe keeping if you wish.

root@s200:~# ls  /opt/sark/bkup/
sarkbak.1365735601.zip	sarkbak.1365994801.zip	sarkbak.1366254001.zip
sarkbak.1365822001.zip	sarkbak.1366081201.zip	sarkbak.1366340401.zip
sarkbak.1365908401.zip	sarkbak.1366167601.zip	sarkbak.1366348979.zip
root@s200:~# ls  /opt/sark/snap/
sark.db.1366024598  sark.db.1366024836	sark.db.1366111208
sark.db.1366024698  sark.db.1366024898	sark.db.1366297330
sark.db.1366024783  sark.db.1366111077	sark.db.1366315607

As you can see from the listings above, the file names end in a ten-digit number. This is actually the Linux "epoch" timestamp at the time the backup or snap was taken. This means that even if, for example, the file is moved to another system, it is still easy to determine the date it was created. Just go to http://www.epochconverter.com/ and paste the epoch into the converter you will find there. Here is an example using the file sark.db.1366315607 from the listing above.



V4 backup 6.png



Backup Vs Snapshot

A backup is a zip folder containing the SARK database, all voice-mails on the system, all usergreetings and the asterisk control folder.

A snapshot is a copy of the SARK database only.



V4 backup 1.png




Taking an instant backup or snapshot

You can take an instant backup by clicking the blue "backup" button at the top right of the backup panel. You can take an instant snapshot by issuing a commit.

Regress/Restore

You can regress the system to any previous snapshot by clicking on the regress icon for that entry on the snapshot panel (see below).



V4 backup 5.png



This will regress the database back to the image you've chosen. If you then press commit, the regression will be applied to the running PBX. Restoring from a full backup is more complex since it is designed to be used after a catastrophic failure such as failed or corrupted media.