Skip to main content
Solved

SAP HANA online full and related logs


Forum|alt.badge.img+5

Hello, 

customer is managing SAP HANA backups from DB side via backint. He want to create special 3rd copy of his online full backups.

On commvault side, DB backups are taken by DB_backup storage policy and log backups are taken by Log_backup storage policy. 

As per my understanding, due to whole backup process is controlled by HANA Studio (or similar tool), Commvault cannot control what and when is backed up and therefore is kind of blind. 

I was able to setup aux copy of monthly Online full backups to S3 library. We are now testing restore from S3 library (it is 3rd copy), but is failing. Failure reason is caused by absence of log backups. 

Customer now wants to schedule aux copy of Log jobs related to the particular Monthly Online full. I am, however, not sure if it is possible due to mechanism of backups - as I mentioned, they are taken by DB itself and therefore I expect Commvault is not able to “choose” needed log jobs. 

Conclusion: Is it possible to fulfill customer expectation and schedule aux copy job for log jobs related to Monthly Online full backups of SAP HANA? Or is it possible to schedule aux copy, which will take only several Log backup jobs “around the time” when Online full is taken? 

Thank you

Best answer by Albert Williams

 Hello @lubimkomvolt 

An Aux copy job is going to just move all the data that is “picked for copy”. If you run that job every day or once a month it wont change what is “picked for copy”. 

Changing what is auto picked is not going to work for you either as selective Aux copy configuration wont work unless there are fulls in the mix. For example you can move "last full of the month”. There is no way to configure it to select just a few log backups. You could achieve it by manually selecting the jobs but that seems like to much work to be doing every week. 


I recommend just keeping your logs and fulls for the same amount of time and in the same locations you want to be able to do Point in time restores from.

 

Kind regards

Albert Williams

View original
Did this answer your question?

6 replies

Forum|alt.badge.img+15

Hello @lubimkomvolt 

My first question is why are you not able to restore data that is in a full backup. there should be no dependencies to perform that backup and it should not fail due to missing log backups. 

 

In regards to Aux coping the data over, you can setup the Storage policy or plan to have the extra copies and it will move the data where it needs to be. When a restore job starts it will list out all of the jobs it needs to achieve that and then go looking for the copies of that data based on the president outlined and availability. 

 

Kind regards

Albert Williams


Forum|alt.badge.img+5
  • Author
  • Byte
  • 15 replies
  • August 22, 2024

Hi @Albert Williams

to respond your first question, as I mentioned customer is responsible for SAP HANA management and backup mechanism. I was told in case of SAP HANA  only Offline full backup would let us to do restore without logs. But they are taking Online fulls. We also proved it by restore test. To bring more details let me mention retentions and how we did it. 

  1. we have a storage policy for full backups with retention of 5days in primary and secondary copy on disk library
  2. we have storage policy for log backups with retention of 5 days in primary and secondary copy on disk library
  3. we have S3 library for monthly full backups with retention of 30days where only online fulls are stored via aux copy inside storage policy mentioned in point 1
  4. log backups are not transferred to S3 library

We have tested SAP HANA restore from date which is over basic 5 days retention, from S3 library. Restore failed with 

“Error Code: [18:146] Description: SAP HANA Error [hdbsql execution Failed. 449: recovery strategy could not be determined: [111014] The backup with backup id '1723466621353' cannot be used for recovery SQLSTATE: HY000].”

I have checked the backup ID from the message and it is not representing ID of online full. And I was not able to locate it, therefore I am assuming it is ID of some log backup. 

Than we tested SAP HANA restore from date within 5 days retention, from S3 library. It passed and immediately after “my restore” finished a new restore of “Application Command Line Restore” was triggered automatically by commvault or by DB (I am not sure in this case). 

 

Thanks 


Forum|alt.badge.img+15

Hello @lubimkomvolt 

 

I suspect the type of restore you are doing is a point in time restore and not from a specific backup job. 

The way HANA will trigger the restore it is going to be a point in time restore and want the logs as well. 

I recommend just Aux copy all your logs as well as they are going to be required for any Point in time restore for SAP HANA

 

Kind regards

Albert Williams


Forum|alt.badge.img+5
  • Author
  • Byte
  • 15 replies
  • August 23, 2024

Hello @Albert Williams

you are right, it suppose to be point-in-time restore. In our case, as I need to keep logs alongside fulls, I have further question. 

I need to keep only logs for one full of the month. Lets say, I will keep only logs 24hours around monthly online full. I have doubts how to schedule such aux copy. How to configure aux copy to take only those logs, only logs one time per month from time window of 24hours. I am not sure if it is clear what I am to, sorry :)

I can schedule aux-copy to run once per month, lets say last Sunday, but than it will take all log backups for the particular client and copy everything over to S3. Or am I mistaken?

Thank you


Forum|alt.badge.img+15

 Hello @lubimkomvolt 

An Aux copy job is going to just move all the data that is “picked for copy”. If you run that job every day or once a month it wont change what is “picked for copy”. 

Changing what is auto picked is not going to work for you either as selective Aux copy configuration wont work unless there are fulls in the mix. For example you can move "last full of the month”. There is no way to configure it to select just a few log backups. You could achieve it by manually selecting the jobs but that seems like to much work to be doing every week. 


I recommend just keeping your logs and fulls for the same amount of time and in the same locations you want to be able to do Point in time restores from.

 

Kind regards

Albert Williams


Forum|alt.badge.img+5
  • Author
  • Byte
  • 15 replies
  • August 26, 2024

Hello @Albert Williams

many thanks for all your answers. My theory confirmed :) 

 


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings