Friday 26 February 2016

Delta Backups

This blog will be about a new feature in HANA SP10, delta backups.

What is a Delta Backup?
Starting with SPS 10 delta backups were introduced, this feature allows users to perform backup and recoveries quicker. Delta backups only capture the data changed since the last backup or delta backup, meaning less log backups are read for a recovery.
There are two options available when creating a delta backup:
Differential Backup - stores all data changed since the last full backup.
Incremental Backup - Stores the data changed since the last full or last delta backup. These backups are smaller than the differential backups.

How to Create a Delta Backup?
First choose a user that has the BACKUP ADMIN authorization, in this case we will be using the SYSTEM user.
Right click on the system you would like to create a backup for

SAP HANA Certifications and Material
In the ‘Backup Type’ select the delta backup options

Delta Backups

Delta Backups

Delta Backups

Delta Backups

This error occurred because I did not create full data backup prior to making this delta backup, as mentioned before delta backups are just the difference between the current time to the last full backup. The nameserver trace will show the following:

[23117]{300068}[-1/-1] 2016-02-12 20:18:27.643831 i Backup           BackupMgr_DeltaBackupTracker.cpp(00845) :  [DBT] received BackupCatalog_DifferentialBackupStartEntry for 1455308307601
[23117]{300068}[-1/-1] 2016-02-12 20:18:27.644641 i Backup BackupMgr_DeltaBackupTracker.cpp(00113) : No data backups found.

After we create a full data backup in the nameserver trace we will see:

i Backup BackupMgr_DeltaBackupTracker.cpp(00845) :  [DBT] received BackupCatalog_DifferentialBackupStartEntry for 1455309927467
e Backup BackupMgr_DeltaBackupTracker.cpp(00957) : Requested volume 0 not found in backup tracker.
i Backup BackupMgr_DeltaBackupTracker.cpp(00685) :  [DBT] received BackupCatalog_DataDestinationStartEntry for 1455309927467
backup.log will show:
BACKUP   SAVE DATA will write to the following files:
INFO    BACKUP   to file: /usr/sap/xx/HDB00/backup/data/DIFF_DATA_BACKUP_databackup_differential_0_1455309927467_0_1
INFO    BACKUP   to file: /usr/sap/xx/HDB00/backup/data/DIFF_DATA_BACKUP_databackup_differential_1455309613593_1455309927467_1_1
….
INFO    BACKUP   SAVE DATA finished successfully
As we can see the only way to tell it is a differential backup is by the filename
*PREFIX*_databackup_differential
Incremental backups are done the same

SAP HANA Certifications and Meterial

And the logs are not much different as it just shows the file name is *PREFIX*_databackup_incremental (IE. INC_DATA_BACKUP_databackup_incremental_0_1455310512146_0_1)
Please note that in SPS 10 you cannot create a delta backup in the HANA Cockpit, but this feature is available in HANA SPS 11
HANA SPS 10 will show the delta backup options as disabled

Delta Backups

Viewing Backups
You can view the backups in the HANA Studio by opening the backup wizard

Delta Backups

To see our delta backups are not there, to see them we will need to check ‘Show Delta Backups’

Delta Backups

Please note in the HANA cockpit the delta backups are not visible and not option to view them (SPS 10>
Delta Backups

What About Recoveries?
Recoveries are performed the same as before

Delta Backups

Delta Backups

Please note that if you choose ‘Recover the database to a specific data backup or storage snapshot’ you won’t have the option to select a delta
Select the log area

SAP HANA Delta Backups

Select the data backup

Delta Backups

After this we can select the delta backup option

Delta Backups

Please note that if you selected ‘Recover the database to a specific data backup or storage snapshot’ this option will be grayed out.

Source: scn.sap.com

No comments:

Post a Comment