2022-06-13 2096851 2096851 - Backup Catalog Housekeeping within SAP HANA Version 13 Type SAP Knowledge Base Article Language English Master Language English Release Status Released to Customer Category Problem Component HAN-DB-BAC (SAP HANA Backup & Recovery) Released On 30.07.2020 Please find the original document at https://launchpad.support.sap.com/#/notes/2096851 Symptom • You observe the size of log backup growing continuously; • The file name of the log backup that is unexpectedly big starts with "log_backup_0_0_0_#########"; • The file system where SAP HANA log backups are stored is filling rapidly or has reached 100% causing the database to hang; • The indexserver trace file show errors similar to the following: [72007]{-1}[-1/-1] 2015-01-18 09:12:54.379241 e Backup BackupExe_LogBackup.cpp(00472) : Report backup failure: Cannot open file ""<root>/.log_backup_5_0_5068115968_5068116992.1421572374350" (mode= W, access= rwrwr-, flags= DIRECT|UNALIGNED_SIZE|TRUNCATE|MULTI_WRITERS), factory= (root= "/backup/log_backup/<SID>/" (access= rwrwr-, flags= AUTOCREATE_PATH|DISKFULL_ERROR, usage= LOG_BACKUP, fs= nfs, config= (AsyncWriteSubmitActive=auto,AsyncWriteSubmitBlocks=new,AsynReadSubmit=off,#SubmitQueues=1,#Comple rc=28: No space left on device [72007]{-1}[-1/-1] 2015-01-18 09:13:54.388498 e Logger BackupHandlerImpl.cpp(00390) : Error during log segment backup: exception 1: no.2000004 (Basis/IO/FileAccess/impl/LocalFile.cpp:177) • The backup.log file shows errors similar to the following: 2015-01-18T09:09:27+00:00 P051968 14afc4dd68c INFO LOGBCKUP state of service: nameserver, hand04:39701, volume: 1, BackupLogStarted 2015-01-18T09:09:27+00:00 P051968 14afc4dd68c INFO LOGBCKUP to file: /backup/log_backup/<SID>/log_backup_1_0_166160768_166164608.1421572167308 2015-01-18T09:09:27+00:00 P051968 14afc4dd68c INFO LOGBCKUP state of service: nameserver, hand04:39701, volume: 1, BackupLogError 2015-01-18T09:09:38+00:00 P051968 14afc4e0349 INFO LOGBCKUP state of service: statisticsserver, hand04:39705, volume: 2, BackupLogStarted 2015-01-18T09:09:38+00:00 P051968 14afc4e0349 INFO LOGBCKUP to file: /backup/log_backup/<SID>/log_backup_2_0_8174898432_8175824512.1421572178761 2015-01-18T09:09:38+00:00 P051968 14afc4e0349 INFO LOGBCKUP state of service: statisticsserver, hand04:39705, volume: 2, BackupLogError • You want to know how to perform the housekeeping of the backup catalog in SAP HANA; Environment SAP HANA, platform edition © 2022 SAP SE or an SAP affiliate company. All rights reserved 1 of 3 2022-06-13 2096851 Cause 1. The location of the data and log backups have been left at the default location of /usr/sap/<SID>/<HOST>/backup/data and /usr/sap/<SID>/<HOST>/backup/log'. 2. Backup logs are now filling up the filesystem; Resolution It is possible to remove old backups from the HANA database using the following procedure: 1. Issue the SQL command 'ALTER SYSTEM RECLAIM LOG' to free up log segments; 2. Next, in SAP HANA Studio, go to the Backup and Recovery menu and choose the Backup Catalog tab; 3. Locate any old backups that are no longer needed and right click the backup; 4. Click 'Delete Data Backups' and choose the 'Catalog and Backup Location' radio button: 5. Click 'Finish' to execute; Remarks: • It is recommended to store data backups and log backups away from the default location of '/usr/sap/<SID>/<HOST>/backup/data' and '/usr/sap/<SID>/<HOST>/backup/log' to a location with ample space away from the HANA appliance software. Changing data backup and log backup settings can be done by selecting the 'Configuration' tab within the Backup and Recovery menu and altering the destination of the log files. • This can be done online and the SAP HANA will start using this new location once finished writing to the previous log backup. • No database restart is required. • Do NOT delete log files at OS level as this can render the HANA database inconsistent and unusable and will result in the need for a database recovery; • Alternatively to Deletes backups from the backup catalog using BACKUP CATALOG DELETE Statement; See Also • SAP Note 1642148 - FAQ: SAP HANA Database Backup & Recovery • Housekeeping: Deleting and Archiving Backups • Monitoring Disk Space Keywords DISKFULL_ERROR, Disk full, AUTOCREATE_PATH|DISKFULL_ERROR, rc=28: No space left on device, Cannot open file, Delete Data Backups, alter system reclaim log, Catalog and Backup Location © 2022 SAP SE or an SAP affiliate company. All rights reserved 2 of 3 2022-06-13 2096851 Products SAP HANA, platform edition all versions Other Components Component Description HAN-CPT-CPT2-BAC SAP HANA Cockpit 2 Backup & Recovery This document refers to SAP Note/KBA 1642148 Title FAQ: SAP HANA Database Backup & Recovery BACKUP CATALOG DELETE Statement (Backup and Recovery) Housekeeping: Deleting and Archiving Backups ALTER SYSTEM RECLAIM LOG Monitoring Disk Space Terms of use | Copyright | Trademark | Legal Disclosure | Privacy © 2022 SAP SE or an SAP affiliate company. All rights reserved 3 of 3