cancel
Showing results for 
Search instead for 
Did you mean: 

Calculate needed space in case you need to backup to disk

Former Member
0 Kudos

Hei,

I have the following practical question regarding Hana Log Backups.

Normally the Log Backups are set to: Automatic send to an external location using backint integration.

But if the external location is unavailable (defect or maintenance) we need to switch to file backup for Log Backups.

The question now is the following:

Given is that the external backup location is unavailable for 48 hours.

Hana is up and running.

I want to calculate how many MB it has written to Log Backup the last 48 hours.

With this info I can make a calculation (not 100% but ok for me) how big the filesystem should be where I can send the File Log Backups to.

Who has any tips on how to attack this question ??

Credits for the good tip/hint

Kind regards,

Frans Trip

Accepted Solutions (1)

Accepted Solutions (1)

former_member182967
Active Contributor
0 Kudos

Hi Johan,

Assuming there is no big change during daily business operation, the daily space required for log backup in filesystem can be got from the daily size report (check your third-party backup tools) of log backup using backint.

Regards,

Ning

Former Member
0 Kudos

Ok,

But my Third party backup tool is unavailable (in this example due to failure/maintenance. So I need to get this info from Hana.

Regards,

Frans

0 Kudos

Hi,

i think Ning meant that you do that prior to your failure/maintenance case. Assuming that your Backup tool is currently running, check what size HANA writes into your 3rd Party Backup tool over 38 hours.

That way you know the size.

Regards

-Seb.

former_member182967
Active Contributor
0 Kudos

Hi Johan,

1. In SAP HANA studio, go to the Systems view.

2. Open a system.

3. Double-click Backup.

4. Check size of log backup in Backup Catalog tab -> Show Log Backups (you need to manually calculate the total size).

Or you can also view information (manually write some SQL to calculate total size for log backup) using monitoring views M_BACKUP_CATALOG and M_BACKUP_CATALOG_FILES.

Regards,

Ning

Former Member
0 Kudos

I am more thinking about a Query on the Backup catalog.

Find the log backup numbers written the last 48 hours (current time - 48 hours)

check Source size for the backup numbers in the time frame and add them up.

Regards,

Frans

Former Member
0 Kudos

Hi Frans,

Try the following SQL which will give you a daily sum of the backed up logs. It's not elegant but it gets you the daily info.

select TO_DATS(t1.SYS_END_TIME), sum(t2.backup_size)   FROM SYS.M_BACKUP_CATALOG t1, SYS.M_BACKUP_CATALOG_FILES t2 WHERE t1.entry_id = t2.entry_id  AND (t1.ENTRY_TYPE_NAME =  'log backup')   and (rtrim(t1.STATE_NAME) =  'successful')  group by  TO_DATS(t1.SYS_END_TIME) ;

Cheers,

Amerjit

Answers (0)