Skip to main content
< All Topics
Print

High log space usage

To query the Performance Store database for databases where the used log space is more than 70% of the available log space within the transaction log file, use:

select d.server_name, d.database_name, d.data_size_mb, d.log_size_mb, isnull(d.log_space_since_last_backup_mb, 
0) log_space_since_last_backup_mb, isnull(d.used_log_space_in_percent, 0) used_log_space_in_percent
from dbo.v_databases d
where (d.role_desc is null or d.role_desc = 'PRIMARY')
and d.log_size_mb >= 500
and d.used_log_space_in_percent > 70

A quick overview of the log space usage can be seen on the Overview 1 dashboard:

The alert will be visible on the Latest stats dashboard.

To exclude specific servers from this alert, see how to use the dbo.team_alert_exclude table in Alerting.

Table of Contents