This post outlines new and enhanced features of SAP HANA backup and recovery with Support Package Stack 10.
The information here has been collected from several sources with the intent of making it more accessible to people interested.
Contents
- Recovery Using Delta Backups
- Backup Functionality in SAP HANA Cockpit
- Support for SAP HANA Multitenant Database Containers
- DBA Cockpit for SAP HANA: New Backup Functionality
- New Monitoring View: Progress of Backup
- Which SAP HANA Tool Supports What?
- More Information
Recovery Using Delta Backups
With SPS10, SAP HANA supports recovery using delta backups (incremental and differential backups).
Full Backups and Delta Backups
SAP HANA now supports the following backup types:
From SPS10,a full backup is used to mean:
- Data backup
A data backup includes all the data structures that are required to recover the database. - Storage snapshot
A storage snapshot captures the content of the SAP HANA data area at a particular point in time.
From SPS10, SAP HANA now supports the following delta backups:
- Incremental backup
An incremental backup stores the data changed since the last data backup - either the last data backup or the last delta backup (incremental or differential). - Differential backup
Differential backups store all the data changed since the last data backup.
Note that delta backups (incremental or differential) contain actual data, whereas log backups contain redo log entries.
Delta backups are included in the backup catalog.
When you display the backup catalog, delta backups are hidden by default.
To display delta backups in the backup catalog:
- In SAP HANA studio, open the Backup Console and go to the Backup Catalog tab.
- Select Show Delta Backups.
You can use both incremental and differential backups in your backup strategy.
Backup lifecycle management now also includes delta backups.
When you delete all the backups older than a specific full backup, older delta backups are also deleted along with older full backups and log backups.
SAP HANA Recovery Options Using Delta Backups
If delta backups are available, they are included by default in a recovery. In the recovery dialog in SAP HANA studio, you can choose to perform a recovery without using delta backups:
If you include delta backups, SAP HANA automatically determines the optimal recovery strategy based on all the available backups.
Recovery to the Most Recent State
What you need:
- A data backup
AND - The last differential backup
Note:
This is only supported for a data backup, not for a storage snapshot.
AND - Subsequent incremental backups
Note:
This is only supported for a data backup, not for a storage snapshot.
AND - Subsequent log backups
AND - Redo log entries that are still available in the log area
(If the log area is still available.)
Recovery to a Point in Time in the Past
What you need:
As for a recovery to the most recent state.
Redo log entries from the log area may not be needed.
SQL Statements for Recovery Without Delta Backups
By default, SAP HANA includes delta backups in a recovery.
If you wish to recover SAP HANA without using delta backups, you can use the following SQL statement:
RECOVER DATABASE UNTIL TIMESTAMP '<timestamp>' IGNORE DELTA DATA BACKUPS
Example:
RECOVER DATABASE UNTIL TIMESTAMP '2015-05-15 10:00:00' IGNORE DELTA DATA BACKUPS
Finding and Checking the Backups Needed for a Recovery
You can use hdbbackupdiag to display the backups needed to recover the database.
In this way, you can minimize the number of backups that need to be made available for a recovery.
With SPS10, hdbbackupdiag supports delta backups.
More information: Checking Whether a Recovery is Possible
Prerequisites for Performing a Recovery
- Operating system user <sid>adm
- Read access to the backup files
- System privilege DATABASE ADMIN
(for tenant databases in a SAP HANA multiple-container system)
Third-Party Backup Tools and Delta Backups
Delta backups are compatible with the current API specification for third-party backup tools (Backint).
- For delta data backups, SAP HANA uses the Backint option -l LOG in combination with the data Backint parameter file:
-p /usr/sap//SYS/global/hdb/opt/hdbconfig/initData.utl
Third-party backup tools sometimes use the Backint option -l to determine the backup container using the Backint parameter file.
This means that for the option –l LOG, the log backup container is used. - Caution:
Backup containers that were, until SPS10, only used for log backups may be sized too small for delta backups.
If a log full situation occurs, this could cause a database standstill. - The Backint parameter file is tool-specific and typically contains information such as the backup destination.
Note: Some third-party backup tools support only one Backint parameter file for both data and log backups - Recommendation:
Ask your backup tool vendor for details of how to configure the tool to work with delta backups.
If in doubt, configure two dedicated Backint parameter files: one for data backups, and one for log backups.
SQL Statements for Delta Backups
To create an incremental backup, use the following SQL statement:
BACKUP DATA INCREMENTAL USING FILE ('<file name>')
If the file name is ‘2015-08-03’, this SQL statement creates the following delta backup files:
Data backup file: 2015-08- 03_databackup_incremental_0_1431675865039_0_1
Data backup file: 2015-08- 03_databackup_incremental_1431675646547_143167586 5039_1_1
Data backup file: 2015-08- 03_databackup_incremental_1431675646547_143167586 5039_2_1
Data backup file: 2015-08- 03_databackup_incremental_1431675646547_143167586 5039_3_1
To execute a differential backup, use the following SQL statement:
BACKUP DATA DIFFERENTIAL USING FILE ('<file name>')
If the file name is ‘2015-08-03’, this SQL statement creates the following delta backup files:
Data backup file: 2015-08- 03_databackup_differential_0_1431675646547_0_1
Data backup file: 2015-08- 03_databackup_differential_1431329211296_1431675646547_1_1
Data backup file: 2015-08- 03_databackup_differential_1431329211296_14316756 46547_2_1
Data backup file: 2015-08- 03_databackup_differential_1431329211296_14316756 46547_3_1
In this example, 1431329211296 is the backup ID of the basis data backup; 1431675646547 is the backup ID of the delta backup.
Prerequisites for Working with Delta Backups
System privilege BACKUP ADMIN, BACKUP OPERATOR (recommended for batch users only), or DATABASE ADMIN (for MDC)
More Information
Backup Functionality in SAP HANA Cockpit
In addition to SAP HANA studio, you can now also start SAP HANA backup operations from SAP HANA cockpit.
From SAP HANA cockpit, you can:
- Create data backups
- Display information about data backups
Create Data Backups in SAP HANA Cockpit
Using SAP HANA cockpit, you can create data backups.
- In SAP HANA cockpit, click the Data Backup tile.
- Choose Start New Backup and specify the backup settings.
- To start the backup, choose Back Up.
The overall progress is displayed on the Data Backup tile.
To see more details of the backup progress, click the tile.
Display Information About Backups in SAP HANA Cockpit
If a backup is running, the Data Backup tile displays its progress.
If no backup is running, the Data Backup tile displays the status of the most recent full backup:
- Successful
- Running
- Snapshot Prepared
- Canceled
- Error
Click the tile to display more details from the backup catalog:
The following information is displayed:
- Time range that the backup catalog covers
- Total size of the backup catalog
Information about the most recent backups within the time range
(status, start time, backup type, duration, size, destination type and comment)
Click a row to display more details:
Prerequisites for Creating Backups in SAP HANA Cockpit
- System privilege BACKUP OPERATOR or BACKUP ADMIN
- Role:
- sap.hana.backup.roles::Operator
or - sap.hana.backup.roles::Administrator
- sap.hana.backup.roles::Operator
Notes
Storage snapshots, backup lifecycle management, and database recovery are currently not supported in SAP HANA cockpit.
More Information
SAP HANA Administration Guide: SAP HANA Database Backup and Recovery
Support for SAP HANA Multitenant Database Containers
In SAP HANA studio, the steps to recover a SAP HANA multitenant database container system are similar to the steps to recover a SAP HANA single-container system.
Note:
Storage snapshots are currently not supported for SAP HANA multitenant database container systems.
The system database plays a central role in the backup and recovery of SAP HANA multitenant database containers:
- The system database can initiate backups of the system database itself as well as of individual tenant databases.
A tenant database can also perform its own backups (unless this feature has been disabled for the tenant database) - Recovery of tenant databases is always initiated from the system database
- To recover a complete SAP HANA multitenant database container system, the system database and all the tenants need to be recovered individually.
SAP HANA Multitenant Database Containers and Third-Party Backup Tools
When you work with third-party backup tools and SAP HANA multitenant database container system, you should be aware of some specific points:
Isolation Level “High”
With SPS10, a new option “isolation level” was introduced for SAP HANA multitenant database container systems.
In isolation level high, each tenant database has its own dedicated operating system user.
In high isolation scenarios, Backint is supported by SAP HANA. However, you should check with your third- party tool vendor whether any tool-specific restrictions apply.
Tenant Copy
Tenant copy using Backint is currently not supported.
To copy a tenant database using backup and recovery, use file system-based backups instead.
DBA Cockpit for SAP HANA: New Backup Functionality
DBA Cockpit for SAP HANA supports the following SAP HANA SPS10 functionality:
- Delta backups (incremental and differential backups)
This feature is available with the following SAP_BASIS Support Packages and above:- 7.50 SP01
- 7.40 SP13
- 7.31 SP17
- 7.30 SP14
- 7.02 SP18
- Backups of tenant databases
All tenant databases in an SAP HANA multitenant database container can be backed up independently of each other.
This feature is available with the following SAP_BASIS Support Packages and above:- 7.40 SP10
- 7.31 SP15
- 7.30 SP13
- 7.02 SP17
Note that tenant database, on which the DBA Cockpit is installed, is supported "out-of-the-box".
No additional setup steps are necessary in DBA Cockpit.
System databases need to be integrated manually.
More information: SAP Help Portal -> DBA Cockpit for SAP HANA -> Add a Database Connection
To schedule backups:
- In DBA Cockpit, Choose
Alternatively, use SAP transaction DB13. . - To schedule a new data backup, drag an item from the Action Pad to a cell in the calender.
To back up a tenant database, choose Complete Data Backup.
Tenant databases are backed up from within the system database. - In the dialog box, specify the information required.
For Database Name, specify the name of the tenant database you want to back up. - Choose Add or Execute Immediately.
The backup is scheduled for the time you specified or is started.
More information: SAP Note 2164096 - Schedule backups for SAP HANA multiple-container systems with DB13
New Monitoring View: Progress of Backup
M_BACKUP_PROGRESS provides detailed information about the most recent data backup.
Here is a comparison of M_BACKUP_PROGRESS and M_BACKUP_CATALOG / M_BACKUP_CATALOG_FILES:
M_BACKUP_CATALOG M_BACKUP_CATALOG_FILES | M_BACKUP_PROGRESS |
---|---|
All types of backups (data, log, storage snapshots, if available) | Data backups only (data, delta, incremental) |
All completed and currently running backups since the database was created | Currently running and last finished backups only |
Persistent | Cleared at database restart |
Total amount of data for finished backups only | Total and already transferred amount of data for all backups |
System views are located in the SYS schema.
More information: M_BACKUP_PROGRESS in the SAP HANA SQL and System Views Reference Guide
Which SAP HANA Tool Supports What?
Below is an overview of the backup and recovery functionality supported by the different SAP HANA tools with SAP HANA SPS10:
SAP HANA Studio | SAP HANA Cockpit | DBA Cockpit for SAP HANA | |
---|---|---|---|
Data Backup | YES | YES | YES |
Storage Snapshot | YES | ||
Incremental Backup | YES | YES | |
Differential Backup | YES | YES | |
Schedule Backups | YES | ||
Database Recovery | YES | ||
Support for Tenant Databases | YES | YES |
More Information
SAP HANA User Guides
- SAP Help Portal (SAP HANA Platform)
- SAP HANA Administration Guide
- Technical Operations Manual
- SAP HANA SQL and System Views Reference
Overview Presentation
SAP HANA Backup/Recovery Overview
Training
SAP Notes
- 2165826
Information about SAP HANA Platform Support Package Stack (SPS) 10 - 1642148
FAQ: SAP HANA database backup and recovery - 2031547
Overview of SAP-certified 3rd party backup tools and associated support process - 2039883
FAQ: SAP HANA database and storage snapshots - 2165547
FAQ: SAP HANA Database Backup & Recovery in a SAP HANA System Replication landscape - 2091951
Best Practices for SAP HANA Backup and Restore
Further SAP notes are available on component HAN-DB-BAC