Loading...

HDBSQL Example: Recovering the SAP HANA 1.0 Tenant Databases for a Disaster Recovery

Use this procedure for a disaster recovery situation.

After you restore the SAP HANA SYSTEMDB, restore the tenant databases

Note: You must restore the SYSTEMDB and all tenant databases.

Before You Begin

  1. Restore the SYSTEMDB. For more information, see  HDBSettings.sh Example: Performing SAP HANA 1.0 SYSTEMDB Restores for Disaster Recovery.
  2. Make sure that you have the following information:
    • The source instance SID name
    • The SAP HANA source physical client name
  3. Update the SAP HANA parameter file with the following entries:
    • srcCrossClient - This is the source physical client name.
    • srcCrossDbName - This is the source database name.
  4. Stop the SAP HANA tenant database. On the command line, type the following command:

    Note: You can run this command from SAP HANA Studio in the SQL console.

    hdbsql -U BACKUPM "alter system stop Database TENANTDBNAME"

Procedure

  • Select one of the following recovery options:
    • Recover to the most recent backup. On the command line, type the following command substituting the timestamp that is in the future and the source SID (in this example, W02).

      hdbsql -U BACKUPM "RECOVER DATABASE FOR TENANT UNTIL TIMESTAMP '2018-10-27 05:59:22' CLEAR LOG USING SOURCE 'W02' CHECK ACCESS USING BACKINT "

    • Recover to a point in time. On the command line, type the following command, substituting the timestamp and source SID (in this example, W02).

      hdbsql -U BACKUPM "RECOVER DATABASE FOR TENANT UNTIL TIMESTAMP '2017-10-27 03:59:22' CLEAR LOG USING SOURCE 'W02' CHECK ACCESS USING BACKINT "

    • Perform a data only recovery. On the command line, type the following command, substituting the backup prefix and source SID (in this example, W02).

      hdbsql -U BACKUPM "RECOVER DATA FOR TENANT USING SOURCE 'W02' USING BACKINT ('4343631_COMPLETE_DATA_BACKUP') CLEAR LOG"

Last modified: 2/26/2018 3:10:21 PM