Restoring a Data Protection for SAP HANA backup on an alternative system

You can restore system copies of your SAP HANA backups to alternative environments for testing or cloning purposes by using the SAP HANA Cockpit or SAP HANA Studio. Use the backint interface for system copies to an alternative server from SAP HANA 1.0 SPS09 and later releases of SAP HANA.

Before you begin

To restore data on an alternative system with Data Protection for SAP HANA, the profiles for both the source and target SID (system identifier) must exist on the alternative system. SAP HANA restores the data by using the source SID profile and on completion of the restore, starts log backups by using the new SID profile. You must adjust the SAP HANA configuration to use the correct profile. The SAP HANA® Administrator's Guide describes the requirements and advises the use of the $(SAPSYSTEMNAME) within the SAP HANA configuration.

For example, in the following screen capture $(SAPSYSTEMNAME) replaces the SID with the location of the IBM Spectrum Protect for Enterprise Resource Planning profile, which allows the processing to dynamically pick up the correct .utl file. The integrity of the backups is ensured.

Backint parameter file location on Configuration tab
Important: In the dsm.sys configuration file, use Passwordaccess prompt rather than passwordaccess generate. Passwordaccess prompt ensures that the restore runs with root authority and accesses the backup data, regardless of the user that is doing the restore.

About this task

To facilitate the restore, it is helpful to use a backup that has a unique name. You can specify a unique backup prefix when you create a backup from the SAP HANA hdbsql command line. The SID of the database can also be included to help identify the system that was backed up, or in this case, the $(SAPSYSTEMNAME) variable, so as to ensure the integrity of the backups as mentioned previously. For example:
hdbsql -i 0 -u system -p manager
 \"backup data using backint
('/usr/sap/PRD/backup/data/COMPLETE_DATA_BACKUP_$(SAPSYSTEMNAME)_$(date +\%Y%m%d_\%T)')\""

You can also schedule this configuration in crontab. For more information, see Crontab file sample.

Procedure

  1. Start the SAP HANA Studio application or go to the SAP HANA Cockpit in your web browser.
  2. In the SAP HANA Studio Navigator tab, right-click to select the instance. Select Recovery. For SAP HANA Cockpit, navigate to the instance and click the Recovery pane.
    If the database instance is still running, a message might be displayed. The message states that the system must be shut down. When you confirm the message, the instance is automatically shut down.
  3. Choose the next actions from SAP HANA Studio or the SAP HANA Cockpit:
    • SAP HANA Studio: In the Specify Recovery Type window, choose the type of recovery that you want to run. In the Locate Log Backups pane, the default location can be used.
    • SAP HANA Cockpit: In the Recover Database pane, click Copy Database.
  4. You can select whether you want to perform the alternative restore (system copy) of the database by:
    • Selecting the backup from the HANA catalog.
    • Directly specifying the prefix for the uniquely named backup.
  5. To select the wanted backup from the HANA backup catalog, in the Specify Backup Location pane, click Recover using the backup catalog, and then choose the Search for the catalog in backint only option.
  6. To directly specify the prefix, in the Specify Backup Location pane, choose Recover without the backup catalog. If the backup prefix is not specified, a list of backups is generated from the SAP HANA recovery catalog, otherwise the backup prefix that is specified is the backup that is restored.
    Important:

    By default, the Source System field is set to the SID of the target system. You must specify the SID of the source database instead. For more information, see the SAP HANA Administrator’s Guide.

    SAP Hana Studio, Specify Backup Location, Specify backup without catalog, SID of the source system
  7. When you are restoring a tenant database in a multitenant database container (MDC) environment, it is necessary to use the DBNAME@SID to specify the database that is being restored.
  8. Click Next to go to the Specify Backup to Recover screen.
  9. In the Backup Prefix field, enter the unique backup prefix that you used when you were setting up the backup operation.

What to do next

For more information about restoring and recovering data, see the SAP HANA documentation. Complete steps for restoring a data backup by using the backint third party tools can be referenced in the SAP HANA Administration Guide: Copy a Database Using a Data Backup Only and Third-Party Backup Tools.