SAPFree calculatorPDF, Excel, Word exportSAP HANAAll SAP HANA and Basis tools

SAP HANA Log Volume Full Time Calculator for Log Backup Outages

This calculator shows how many hours an SAP HANA database can keep writing before the /hana/log file system fills when log backups stop, and how full it gets after an outage you choose. It is built for on-call planning: set alert thresholds and decide how fast a broken backint or backup share must be fixed.

Your numbers

GB
%

From M_DISKS for usage type LOG, or the sum of segment sizes in M_LOG_SEGMENTS.

GB/h

Easiest source: hourly sums of log backup BACKUP_SIZE in M_BACKUP_CATALOG_FILES.

MB

Parameter log_segment_size_mb in [persistence]; default 1024.

minutes

log_backup_timeout_s / 60; default 900 s = 15 min.

4 hours

Your results

Hours until log volume is full if log backups stop
27 hrs
At the peak redo rate. Shows 0 if redo rate is 0.
Free log space now
409.6
GB.
Log segments closed per hour
15
Log space held by the normal backup interval
3.75
GB waiting for the next log backup in normal operation.
Used after the outage
31.7%
Log full during outage (1 = yes, 0 = no)
0

Linear estimate at a constant redo rate. Batch peaks, savepoint delays and system replication can hold segments longer. Use it to plan alerting, not as a guarantee.

Save results:

Log volume used percent vs outage hours

Sweeps Log backup outage to simulate from 0 to 48, holding your other inputs fixed.

Get your HANA alerting thresholds checked

Send your log volume size, redo rates and current alert settings and we will suggest thresholds that leave time to react.

Optional. The tool and every export work without this. No spam.

Was this tool useful?

How to use it

Enter the size of the log file system and how full it is now; M_DISKS (USAGE_TYPE LOG) or M_LOG_SEGMENTS give this. Take the peak hourly redo rate from your log backups, because log backup volume equals redo written. Check log_segment_size_mb and log_backup_timeout_s in the [persistence] section of global.ini (M_INIFILE_CONTENTS shows the effective values), then slide the outage length. The primary output is hours to full at peak rate. If that is shorter than the time your team needs to notice and fix a backup failure out of hours, you need a bigger log volume, earlier alerts, or a backup target that cannot silently fail.

  • Use the peak hour, not the daily average
  • Check each tenant: every service has its own log volume
  • The risk flag is 1 when the simulated outage fills the log

Why log backups free log space

HANA writes redo into log segments of log_segment_size_mb in the log volume. With log_mode normal, a closed segment can only be reused after it has been backed up and is no longer needed for restart, which requires a savepoint after the changes it contains. M_LOG_SEGMENTS shows each segment's STATE, for example Writing, Closed, Truncated, BackedUp and Free. Many segments that are Closed but not BackedUp mean log backups are failing. If the log file system fills, the database can no longer write redo and stops accepting changes: commits hang and applications freeze until space is freed. SAP Note 1679938 covers the disk full event on the log volume. Never delete log segment files at OS level; that can make the database unrecoverable.

  • Default log_backup_timeout_s is 900 seconds
  • Default log_segment_size_mb is 1024
  • log_mode overwrite frees segments without backup but removes point-in-time recovery

Worked example

A 512 GB log volume is 20 percent used, so 409.6 GB is free. At a peak of 15 GB of redo per hour, the log fills in about 27 hours if log backups stop. That sounds comfortable until a month-end job doubles redo to 30 GB per hour, which halves the window to under 14 hours: a Friday evening backint failure could stop the database by Saturday morning. At 15 GB/h about 15 segments of 1 GB close per hour, and the normal 15 minute backup interval holds about 3.75 GB. Run the sweep at your highest redo hour.

Emergency and prevention

In an outage, fix the cause first: a full or unmounted backup share, an expired backint credential, or a backup catalog error. As soon as log backups succeed, segments move to BackedUp and then Free after the next savepoint. Check the backup console or M_BACKUP_CATALOG for failed log backups and the backup.log trace. Prevention is cheap: alert on failed log backups within one interval, alert on log volume fill above a threshold well before full, and keep the log volume sized so hours to full exceeds your worst out-of-hours response time. With system replication, also watch replication status, because a disconnected secondary can retain log on the primary depending on the operation mode.

Frequently Asked Questions

What happens when the SAP HANA log volume is full?

HANA can no longer write redo, so transactions that change data wait and the system appears to hang. Reads may still work. The usual cause is failed log backups. Restore the backup destination, let log backups run, and segments are freed after backup and savepoint. Do not delete log files manually.

How do I check log segment states?

Query M_LOG_SEGMENTS for HOST, PORT, SEGMENT_ID, STATE and size columns, grouped by STATE. A growing count of Closed segments that never reach BackedUp or Free points at log backup failure. Compare with recent log backup entries in M_BACKUP_CATALOG.

Should I lower log_backup_timeout_s?

A shorter interval reduces potential data loss after a disaster and the log held between backups, but creates more, smaller log backups and catalog entries. The 900 second default suits most systems. It does not help if the backup destination itself is broken.

Can I just switch log_mode to overwrite to free space?

It frees segments without backup, but you lose point-in-time recovery until log_mode is set back to normal and a new full data backup is taken. In production treat it as a last resort decided with the business, not a routine fix.

If you want on-call staff to ask HANA why log backups failed and how much time is left, in plain English on your own servers, we can set that up.