# log_autovacuum_min_duration

> log_autovacuum_min_duration is the PostgreSQL setting that defines the minimum execution time above which autovacuum actions will be logged.
---

> [!NOTE]
> **Fact — official short description:** “Sets the minimum execution time above which vacuum actions by autovacuum will be logged.”

## Identity {#identity}

| Field | Value | Meaning |
| --- | --- | --- |
| Type | `integer` | Upstream pg_settings type |
| Context | `sighup` | Takes effect after configuration reload |
| Unit | `ms` | Raw unit |
| Range | `-1` – `2147483647` | Raw limits in the last observed version |
| Enum values | — | — for non-enum types |
| Category | Reporting and Logging / What to Log | Upstream classification |
| Latest boot value | `600000` | 10 min |
{.fields meta="-"}

## Lifecycle {#lifecycle}

| Fact | Value |
| --- | --- |
| First observed | PG9.0 (research boundary) |
| Present in | PG9.0–19 Beta 3 |
| Removed in | No |
| Introduction commit | Not asserted: predates the PG9.0 research boundary |
| Commit date | — |
| Discussion | — |

## Default history {#default-history}

| Versions | Raw `boot_val` | Unit | Human value |
| --- | --- | --- | --- |
| PG9.0–14 | `-1` | `ms` | -1 ms |
| PG15–19 Beta 3 | `600000` | `ms` | 10 min |
{.full-width caption="Measured PG9.0–19 Beta 3 boot defaults"}

## How it works {#mechanism}

log_autovacuum_min_duration sets the minimum execution time above which autovacuum actions will be logged. -1 disables logging autovacuum actions. 0 means log all autovacuum actions. Each qualifying automatic VACUUM or ANALYZE emits timing and work details; -1 disables these completion records and zero records every action.

log_autovacuum_min_duration is a SIGHUP-context setting: a configuration reload activates the new server value without a restart; subsequent operations that consult it use the refreshed value.

It changes emitted diagnostic data rather than query semantics, but volume, sensitive content, log_line_prefix, destinations, collector throughput, and retention determine operational cost and usefulness.

## Tuning advice {#tuning-advice}

> [!TIP]
> **Advice.** These are workload-specific starting points and must be validated with measurements.

| Workload | Guidance |
| --- | --- |
| OLTP | Tune log_autovacuum_min_duration against an explicit observability question and a measured log-volume budget. Prefer selective thresholds, sampling, or role-level overrides over indiscriminate capture. |
| OLAP | Analytical jobs can justify richer log_autovacuum_min_duration telemetry, but account for long statements, large bind values, and bursty completion patterns in the log pipeline. |
| Small nodes | Keep log_autovacuum_min_duration useful but bounded: verify disk, collector, retention, and redaction capacity before increasing detail or frequency. |
{.full-width}

## Pigsty {#pigsty}

Values use the fixed 8-vCPU, 32-GiB, 100-GiB SSD fixture and render the current Pigsty templates for PG19 Beta 3; this does not assert current Pigsty support for that historical or beta release.

| Template | Effective value | Versus upstream boot | Source expression |
| --- | --- | --- | --- |
| OLTP | `1s` | different | `1s` |
| OLAP | `1s` | different | `1s` |
| CRIT | `1s` | different | `1s` |
| TINY | `1s` | different | `1s` |
{.full-width}

> [!CAUTION]
> **Advice — pending human review.** Fact from the current Pigsty template projection: OLTP: PG9.0–19 Beta 3 = 1s (dcs); OLAP: PG9.0–19 Beta 3 = 1s (dcs); CRIT: PG9.0–19 Beta 3 = 1s (dcs); TINY: PG9.0–19 Beta 3 = 1s (dcs). Advice, pending human review — Editorial inference: A one-second threshold makes unexpectedly slow vacuum maintenance visible across profiles without logging every fast action.

## Common pitfalls {#common-pitfalls}

- Editing log_autovacuum_min_duration without reloading configuration and verifying the effective value and subsequent behavior.
- Enabling richer logging without budgeting collector throughput, storage, retention, and downstream query cost.
- Writing SQL text, bind values, identities, or host data without a redaction and access-control policy.
- Changing log_autovacuum_min_duration globally without a rollback plan and a client or operational compatibility test.

## Related parameters {#related-parameters}

[`log_checkpoints`](/parameters/log-checkpoints/) · [`log_lock_waits`](/parameters/log-lock-waits/) · [`log_lock_failures`](/parameters/log-lock-failures/) · [`log_temp_files`](/parameters/log-temp-files/) · [`log_replication_commands`](/parameters/log-replication-commands/)

## References {#references}

- [PostgreSQL 19 Beta 3 — log_autovacuum_min_duration](https://www.postgresql.org/docs/19/runtime-config-logging.html#GUC-LOG-AUTOVACUUM-MIN-DURATION)
- [PostgreSQL 19 release notes](https://www.postgresql.org/docs/19/release-19.html)
- [Machine-readable GUC export](/data/guc.jsonl)
