Skip to Content

How can we recover a HANA db to a previous state but later than a previous recover?

Sep 29, 2017 at 09:13 AM


avatar image

Dear SAP experts,

We are in the middle of a migration and upgrade project for a customer, migrating their system to SAP HANA Database and upgrading their systems to the latest release available.
During the recovery tests we have found an odd behavior:
if we have a data backup and a complete log sequence to, let's say 2017-09-28 12:00 and perform a recovery to a time (let's say 2017-09-28 11:00:00) the recover will succeed (and bring database to a consistent state very close to the desired target: 2017-09-28 10:59:55), but if after this recover we try to attempt another recover to a 'most recent' past (let's say to 2017-09-28 11:15) it will only recover to the same timestamp as before 2017-09-28 10:59:55, furthermore, any subsequent attempt to restore to a timestamp or log sequence newer than that 2017-09-28 10:59:55 will hang.

We understand that the hanging situation is a bug and that not being able to recover ma be a design feature, according to SAP Note 1642148 - FAQ: SAP HANA Database Backup & Recovery: 'The SAP HANA database will be initialized with the specified data backup. This backup becomes the first backup of a new database life cycle. Older backups are not compatible with the log written after the recovery', however, we need how to proceed to recover. For example consider the following business example:

in 2017-12-01 at 10:30:00 a full data backup takes place. Every ten minutes, a log backup is performed. At 12:00 an user report a human mistake made at 11:01 and management decides to request a recover to 11:00. The Basis team is able to recover the database to 10:59:55 and operation resume, but then the user notice that the mistake actually happened at 11:20 and critical changes that need to be preserved took place at 11:10. If the first recovery hadn't take place, we could have simply recover to 11:15, but after the restore to 10:59:55, it is not possible. Isn't there any way to recover to 11:15? We have a full data backup at 10:30 and log backups all the way up to 12:00... It would be nice to be able to select the log backup you want to apply.

Reproduction steps wold be as follows:
Step 1: Create full data backup (t0)

Step 2: Create log backups (t1, t2,..., tn)

Step 3: Recover database to t1

Step 4: Try to recover database to any timestamp lataer than t1 (t2 and so on).

We are running HANA on SUSE SUSE Linux Enterprise Server for SAP Applications 12 SP2

I guess if we destroy and rebuild the catalog after the first recovery to t1 we can subsequently recover to t2 but I'd like to avoid that.

Thanks in advance for your answers

Best regards,

José Enrique

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

0 Answers