Skip to content

vacuum_max_eager_freeze_failure_rate

vacuum_max_eager_freeze_failure_rate — Fraction of pages in a relation vacuum can scan and fail to freeze before disabling eager scanning. Observed in PG18–19 Beta 3; its last measured boot default is 0.03 in PG19 Beta 3, with user context. This is a beta-snapshot fact and can change before PostgreSQL 19 GA.
Note

Fact — official short description: “Fraction of pages in a relation vacuum can scan and fail to freeze before disabling eager scanning.”

Identity

Type , Valuereal
Upstream pg_settings type
Context , Valueuser
Settable by an ordinary user
Unit , Value
Raw unit
Range , Value01
Raw limits in the last observed version
Enum values , Value
— for non-enum types
Category , ValueVacuuming / Freezing
Upstream classification
Latest boot value , Value0.03
0.03

Lifecycle

Fact Value
First observed PG18
Present in PG18–19 Beta 3
Removed in No
Introduction commit 052026c9b903 — Eagerly scan all-visible pages to amortize aggressive vacuum
Commit date 2025-02-11
Discussion thread 1

Default history

Measured PG9.0–19 Beta 3 boot defaults
Versions Raw boot_val Unit Human value
PG18–19 Beta 3 0.03 0.03

How it works

Fraction of pages in a relation vacuum can scan and fail to freeze before disabling eager scanning. It can be changed at session scope, so different sessions may observe different behavior.

PG18 ordinary VACUUM may eagerly scan all-visible pages that are not all-frozen; it stops that extra work when the fraction scanned without successful freezing grows too high. Raising the rate can shrink later aggressive scans at the cost of more current I/O.

Monitor and change vacuum_max_eager_freeze_failure_rate together with vacuum_truncate, vacuum_freeze_table_age, autovacuum_freeze_max_age. Validate on the relevant server role and real workload, then use its user context to choose session change, reload, or restart; a historical boot default is not the current effective value.

Tuning advice

Tip

Advice. These are workload-specific starting points and must be validated with measurements.

Workload Guidance
OLTP Calibrate vacuum_max_eager_freeze_failure_rate against the oldest XID/MXID age in every database and measured vacuum completion rate. Remove long transactions, stale slots, and blocked workers; never raise ages merely to hide a backlog.
OLAP Proactively VACUUM (FREEZE) newly loaded or static partitions in batch windows and reserve I/O time for full scans. Convert age budgets using peak transaction rate, not a wall-clock guess.
Small nodes Upstream defaults are usually safest. A small system still needs anti-wraparound maintenance; monitor every database, not only the application database.

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 Unmodified
OLAP Unmodified
CRIT Unmodified
TINY Unmodified
Caution

Advice — pending human review. Fact from the current Pigsty template projection: OLTP: PG18–19 Beta 3 unmodified; OLAP: PG18–19 Beta 3 unmodified; CRIT: PG18–19 Beta 3 unmodified; TINY: PG18–19 Beta 3 unmodified. No Pigsty-specific rationale is inferred from an absent override.

Common pitfalls

  • Treating the value as a percentage integer instead of a fraction between zero and one.
  • Raising it and increasing scans of all-visible pages without measuring added I/O and WAL.
  • Assuming eager freezing eliminates the need for periodic aggressive VACUUM.
  • Ignoring a table-level storage-parameter override.
  • Judging success only by pages scanned instead of pages actually frozen and future aggressive-scan work.

vacuum_truncate · vacuum_freeze_table_age · autovacuum_freeze_max_age · maintenance_work_mem · vacuum_failsafe_age · vacuum_freeze_min_age

References