Knowledgebase: Backup Strategies
Volumes, pools and backup strategies
Posted by Sven Koester, Last modified by Sven Koester on 06 June 2012 17:43
This article describes the way PresSTORE allocates data on the media and takes a closer look at how to influence the behavior in detail. |
The basic idea
PresSTORE uses a volume pool to write to. A volume pool is a set of media, let's say tapes, that are used for the backup. PresSTORE maintains itself which data is written on which tapes, it knows how many complete backups are to be kept on the tapes and has multiple strategies to (re-)use tapes when they are to be written again.
PresSTORE is designed to perform backup and archive operations with a maximum amount of automation. In normal operation, there is no need for the user to maintain which data is stored where and on which tape, once a backup pool has been created. One could simply fill a jukebox with tapes, setup a backup plan and define the number of backup cycles to keep in PresSTORE and let it run unattended.
The only disadvantage in this scenario is that all tapes reside in one room: In case of fire or water damage, all tapes are lost. Because of that, it is wise to take some of the tapes to another place; so it is helpful to know which tapes to replace from time to time.
With respect to this question, the following describes some different strategies to create volume pools and backup plans..
A volume pool defines a set of media, these may be tapes or disks or even files within a virtual jukebox.
A backup plan is the schedule as to which files should be saved and when. A backup plan uses one defined volume pool to write to. The backup plan further defines how many backup cycles are to be kept and how tapes are reused.
A backup cycle is an organisation unit. A cycle is beginning with a full backup and includes all incremental backups until the next full backup.
A full backup is a the complete backup of all affected files. Usually, this is done in regular intervals (the backup cycle), but not daily.
An incremental backup is a delta backup, containing all files changed since last backup. In PresSTORE, this means all files since the last incremental or full backup. In case of an incremental backup with time limit (see below), sometimes not all files are saved. If so, they are saved with the next incremental backup. This is a typical kind of backup on a daily base.
A full synthetic backup is a full backup, but not from the original sources but combined together from already performed backups. It may be helpful to compress the backup data without accessing all clients where the data originally came from.
Some backup strategies
The lazy backup
This is a backup style that runs fully unattended. We can setup the following schedule on a weekly base:
What will happen with the leftover 8 tapes? Depending on the selected recycle option set in the volume pool, these tapes are either included in the backup (when volumes are needed), or they are left blank as long as possible (when expiration date is reached) and remain as spare tapes.
The regular backup with regular exchange of the tapes
This is nearly the same as the lazy backup. In addition, the previous full backup is manually removed from the jukebox and weekly brought to an other safe location, thus reducing the risc in kind of a damage. We set up the schedule as before:
This mechanism has side effect: As long as the tapes are exchanged regular , all works fine. But what happens on a holiday? Assuming the tapes are not changed on Monday, the incremental backup of that Monday will be stored on the inserted tape. Assuming there is nobody in the company on that Monday, there should be no problem. In case the data does not fit onto the tapes, the next incremental backup (of Tuesday evening) will collect the remaining files.
A paranoid backup
We want to be as safe as even possible and make a full backup daily, and we take the tapes out the next morning and store them on another location. We set up the schedule as before:
In this scenario, care must be taken how the backup is organized: In normal operation, PresSTORE will attempt to append the backup to the inserted tapes, this will most probably lead to full tapes and an incomplete backup from the 11th day on. This can be avoided by demanding new tapes for each full backup:
Backup Plan -> Additional Options -> Volume Use = Use new media
This way, PresSTORE will try to use a new media when it finds a used media in the drive. Now PresSTORE must decide whether it may reuse the media and overwrite the contents. It does so by testing wether the media belongs to the last x backups to keep and in case no, it re-labels the tape. Care must be taken when setting the number of backup cycles to keep:
Backup Plan -> Additional Options -> Backup cycles to keep: 4
One could assume we have tapes for 10 days, so we set 10, but that would lead to an error, as there cannot be 10 backups kept while overwriting the last. So a maximum value in our scenario is 9. This should work as long as someone notes the date on the tapes and just reuses the eldest. In case we would label the tapes as "Monday" to "Friday", this again will fail after a holiday (when noone exchanges the tape), because the tape of two weeks ago is still one of the last nine backups to keep.
Another point is that PresSTORE up to Version 2.3.7 numbers the cycles on a 24 hour base, which means that two jobs that both end on the same calendar day are counted as one backup. Because of this, and because the backup cycle management in this scenario is actually maintained manually, we suggest a smaller value like e.g. 4. This ensures that the last backups are not overwritten by accident, but allows to reuse a tape even if there is an elder tape contained in the volume pool.