So after having successfully configured the simple Backup, Backup Copy and Replication jobs in VEEAM, we turned our attention to Tape Backups... and like many others hit obstructions on how to achieve a simple GFS backup scheme using VEEAM. Something that many of us have been doing for many years using software like Backup EXEC etc...
However, on our quest to finding the settings for Tape backup that worked for us, I realised that most of the functionality that was required for a simple GFS style offsite tape backup was already present in VEEAM.. However the myriad of options, obscured terminology and lack of clear documentation made it very difficult to make this happen.
Luckily, with trial and error I’ve found settings that enable us to make simple full backups to Tape each night and using the 'Mail Slot' on many Tape libraries make it easy to load / offload tapes every day.
Your mileage may vary, but for us the following settings seem to work best:
-Daily full backups fit on one LTO-6 Tape
-Backup job configured with ‘reverse incremental’
-Tape library (MSL2024) with 1x ‘Mail Slot’ configured
Veeam Tape Configuration:
-Fill the tape library with all the tapes.
-Run an Inventory / Catalog on the Tape library to ensure all the tapes are identified.
-Create a Media Pool for your Tape backup job eg. ‘Daily Tape backup media pool’
-On the ‘Add Tapes to the media pool’ screen, make sure you add all the tapes in the library to this media pool.
-Also, tick the ‘Add tapes from Free media pool automatically’ checkbox.
-On the ‘Media Set’ screen, give the name which will be appended to the tapes for identification. Eg. ‘Daily Tape Backup Set - %date%’
-On the ‘Automatically create new media set’ option, select ‘Create new media set for every backup session’
-On the ‘Retention’ screen, select ‘Do not protect data (Cyclically overwrite tapes as required) option
-For ‘Offline media tracking’, First: create a new Vault by pressing ‘Add New’ and give it a name eg. ‘Offsite Tape Storage Facility’. Second: select the checkbox ‘Move all offline tapes from this media pool into the following media vault, and make sure the ‘Offsite Tape Storage Facility’ vault is selected (which you created in the first step)
-Use the ‘encryption’ option if you wish to and press next -> finish to complete the Media pool configuration.
VEEAM Tape Backup Job:
Now, we move onto creating the actual Tape backup job which will be used to back up the required VM’s to the above created Media Pool. Create a Tape Backup Job with the following settings:
-Name Screen: Give the backup job an appropriate name, eg. ‘Daily Tape Backup Job’
-Backup Files Screen: Select the backup jobs / repositories you wish to backup to tape.
-Media Pool Screen: Select the Media pool which you had created previously eg. ‘Daily Tape backup media pool’
-Options Screen: Uncheck ‘ Use hardware compression’ ; Check Eject media once the job finishes’ and ‘Export current media set once the job finishes’ option.
-Click on the ‘Advanced’ button and in the ‘Advanced’ Tab, tick the pre-job script option. Browse to a folder on your backup server which contains the following 2 files, TapeImport.cmd and TapeImport.ps1. Select the TapeImport.cmd as the pre-job script.
-The contents of TapeImport.cmd and TapeImport.ps1 are as follows :
- Code: Select all
powershell.exe -noprofile -executionpolicy bypass .\VBR-ImportTape.ps1
EXIT /B %errorlevel%
- Code: Select all
Get-VBRTapeLibrary -Name "HP MSL2024 Tape Library" | Import-VBRTapeMedium
-Schedule Screen: click on the ‘Run this job automatically’ option and select the ‘After this job’ option. Select your primary backup job from the selection.
What the above settings do is as follows :
- Before the Tape job is run, the pre-job script checks to see if there is any tape in the 'Mail Slot' which can be imported into the library.. if it finds any tape that has already been allocated to this media pool then it imports the tape and moves it from the 'Mail Slot' and relocates it into any free slot in the Tape Library.
- Put a daily full backup to Tape (.vbk)
- After the backup is completed, the tape is ejected from the tape drive and placed into the 'Mail Slot' for the IT admin to remove it and move it offsite.
- Also, the tape is then marked offline and moved into the virtual vault indicating the physical location of the tape.
What we do is take 1x tape offsite from the previous day and re-introduce the previous days tape back into the library by re-inserting into the 'Mail Slot'
The 3x weekly tapes are stored offsite and reintroduced to the library at the end of month when 1x Monthly Tape is permanently taken off the library and sent off-site for archival storage for 10 years.
I'm sure the above instructions may still not be clear to many people and also may not suit everyone's backup regimes.
Also, i hope the VEEAM team takes hints from this tutorial and creates some sort of official documentation outlining clear instructions on achieving the different types of common tape backup retention schemes like the GFS etc..