Appearance
Vacuum Metrics
This page documents Prometheus metrics related to vacuum operations in Yellowbrick — both autovacuum and manual vacuum — which help manage table bloat, reclaim dead tuples, and prevent transaction ID wraparound.
Purpose
Vacuum metrics are critical for monitoring the health and efficiency of background maintenance processes. They help:
- Track how often tables are vacuumed across databases
- Distinguish between automatic and manual vacuums
- Detect stale or unvacuumed tables (e.g. through long “time since last vacuum”)
- Measure the duration and frequency of vacuum operations
These metrics support bloat management, query performance tuning, and alerting for vacuum starvation or regressions in autovacuum behavior.
Metrics
| Name | Type | Freq | Labels | Description |
|---|---|---|---|---|
yb_active_autovacuum_count | gauge | 1m | - | Number of currently active autovacuum processes |
yb_active_manual_vacuum_count | gauge | 1m | - | Number of currently active manual vacuum processes |
yb_time_since_last_vacuum_seconds_bucket | counter | 1m | le, database_oid | Cumulative count of tables since last vacuum (manual or auto), grouped by database |
yb_time_since_last_vacuum_seconds_count | counter | 1m | database_oid | Total number of vacuumed tables per database |
yb_time_since_last_vacuum_seconds_sum | gauge | 1m | database_oid | Total time since last vacuum across all tables per database |
yb_vacuum_time_seconds_bucket | counter | 1m | le | Cumulative count of vacuum operations running ≤ each duration bucket |
yb_vacuum_time_seconds_count | counter | 1m | - | Total number of currently running vacuum operations |
yb_vacuum_time_seconds_sum | gauge | 1m | - | Total execution time of all currently running vacuum operations |