From cbdce71b9984e9bb2d8b3a4a8de466cbb2c32ea7 Mon Sep 17 00:00:00 2001 From: Nathan Bossart Date: Wed, 19 Nov 2025 10:01:37 -0600 Subject: [PATCH] doc: Update formula for vacuum insert threshold. Oversight in commit 06eae9e621. Reviewed-by: Melanie Plageman Discussion: https://postgr.es/m/aRODeqFUVkGDJSPP%40nathan Backpatch-through: 18 --- doc/src/sgml/maintenance.sgml | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/doc/src/sgml/maintenance.sgml b/doc/src/sgml/maintenance.sgml index 120bac8875f..f4f0433ef6f 100644 --- a/doc/src/sgml/maintenance.sgml +++ b/doc/src/sgml/maintenance.sgml @@ -934,12 +934,16 @@ vacuum threshold = Minimum(vacuum max threshold, vacuum base threshold + vacuum The table is also vacuumed if the number of tuples inserted since the last vacuum has exceeded the defined insert threshold, which is defined as: -vacuum insert threshold = vacuum base insert threshold + vacuum insert scale factor * number of tuples +vacuum insert threshold = vacuum base insert threshold + vacuum insert scale factor * number of tuples * percent of table not frozen where the vacuum insert base threshold is , - and vacuum insert scale factor is - . + the vacuum insert scale factor is + , + the number of tuples is + pg_class.reltuples, + and the percent of the table not frozen is + 1 - pg_class.relallfrozen / pg_class.relpages. Such vacuums may allow portions of the table to be marked as all visible and also allow tuples to be frozen, which can reduce the work required in subsequent vacuums. -- 2.39.5