From 7c15b10a9a7027b77a0a7b9b5b71debcacf2de9a Mon Sep 17 00:00:00 2001 From: Tom Lane Date: Thu, 31 Jan 2008 18:40:02 +0000 Subject: [PATCH] Improve pg_autovacuum documentation to clarify that the enabled field cannot prevent anti-wraparound vacuuming, and to caution against setting unreasonably small values of freeze_max_age. Also put in a notice that this catalog is likely to disappear entirely in some future release. Per discussion of bug #3898 from Steven Flatt. --- doc/src/sgml/catalogs.sgml | 30 ++++++++++++++++++++++-------- 1 file changed, 22 insertions(+), 8 deletions(-) diff --git a/doc/src/sgml/catalogs.sgml b/doc/src/sgml/catalogs.sgml index 29dd25f1cb4..de045d7057d 100644 --- a/doc/src/sgml/catalogs.sgml +++ b/doc/src/sgml/catalogs.sgml @@ -1,4 +1,4 @@ - + @@ -1245,6 +1245,14 @@ about the autovacuum daemon, see . + + + It is likely that pg_autovacuum will disappear + in a future release, with the information instead being kept in + pg_class.reloptions entries. + + + <structname>pg_autovacuum</> Columns @@ -1270,7 +1278,8 @@ enabledbool - If false, this table is never autovacuumed + If false, this table will not be autovacuumed, except + to prevent transaction ID wraparound @@ -1352,7 +1361,9 @@ to prevent transaction ID wraparound if the table's pg_class.relfrozenxid field attains an age of more than freeze_max_age transactions, whether the table - has been changed or not. The system will launch autovacuum to perform + has been changed or not, even if + pg_autovacuum.enabled is set to + false for it. The system will launch autovacuum to perform such VACUUMs even if autovacuum is otherwise disabled. See for more about wraparound prevention. @@ -1364,12 +1375,15 @@ be used for this particular value. Observe that the vac_cost_delay variable inherits its default value from the configuration parameter, - or from if the former is set to a negative - value. The same applies to vac_cost_limit. + or from if the former is set to a + negative value. The same applies to vac_cost_limit. Also, autovacuum will ignore attempts to set a per-table - freeze_max_age larger than the system-wide setting (it can only be set - smaller), and the freeze_min_age value will be limited to half the - system-wide setting. + freeze_max_age larger than the system-wide setting (it can + only be set smaller), and the freeze_min_age value will be + limited to half the system-wide setting. Note that while you + can set freeze_max_age very small, or even zero, this + is usually unwise since it will force frequent vacuuming.