Backup Files and Retention
Backup Files
In the backup repository, logs are stored as .VLB files (Veeam proprietary format) co-located with corresponding SQL Server VM backups (.VBK/.VIB/.VRB files) in the repository folder (default is C:\backup\<SQL_server_VM_backup_job_name>). The backup chain metadata file is also stored in that folder as the .VBM file.
At each start of the SQL Server backup job ('parent'), a new .VLB is created to store log backups in the repository:
- If the Use per-VM backup files option is selected for the repository, then Veeam will create a separate .VLB for each server processed by the job.
- If this option is cleared, then a single .VLB will be created for all servers processed by the job.
For example, if a job processes only one SQL Server, the repository will contain a number of .VLB files for it (a so-called chain).
As described in the section above, during database log backup ('child') job session, transaction log backup is performed by native means of the SQL Server and stored as .BAK file to a temporary folder on the SQL Server VM guest file system. Then Veeam copies .BAK file to the current .VLB in the repository. When the new 'parent' job session starts, another .VLB is created, and the .BAK files that appear after that will be stored there during the 'child' job session. The resulting chain of .VLBs will look like shown below, depicted for a single SQL Server VM1.
Total number of all LOG<N>.BAK files stored at the moment in all VLBs is reported as a number of restore points for the 'child' job that backs up database logs. So, in the example above, the log backup job for SQL Server VM1 has created 8 restore points by the moment.
In the Veeam backup management console the total number of restore points is displayed in the Restore Points column of the preview pane - for both VM and log ( 'parent' and 'child') backup jobs.
Retention
By default, log backups retention policy is set to keep the number of restore points in accordance with the corresponding image-level backup of SQL Server VM. This allows you to have both image-level backup and all the necessary log backups at hand when you need to restore your database from VM backup to a desired state – database will be restored to the closest point before selected moment, and transaction log replay will then bring it to the desired state.
When a database restore point is removed due to VM backup retention settings, the corresponding chain of log backups is removed, too.
Another option allows you to keep only last <N> days. This retention setting can be used, for example, if you plan to save on storage space, saving log backups for the last few days – to be able to restore to some recent database state.
|
Make sure that your SQL Server backup retention and log retention policies are consistent, so that corresponding restore point is always preserved - otherwise, the log replay will not be possible due to the database files missing. |