aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAlexander Korotkov <akorotkov@postgresql.org>2018-06-22 12:17:56 +0300
committerAlexander Korotkov <akorotkov@postgresql.org>2018-06-22 12:26:21 +0300
commit9a994e37e08df3578f52011543dc28085dc18e21 (patch)
tree9cafed5a5706503acf9f0d0f84a88eb710053f3b /src
parent0aa5e65ab4fd2695f0e4108b9ec53a0546261e1f (diff)
downloadpostgresql-9a994e37e08df3578f52011543dc28085dc18e21.tar.gz
postgresql-9a994e37e08df3578f52011543dc28085dc18e21.zip
Fixes for vacuum_cleanup_index_scale_factor GUC option
vacuum_cleanup_index_scale_factor was located in autovacuum group of GUCs. However, it affects not only autovacuum, but also manually run VACUUM. It appears that "client connection defaults" group of GUCs is more appropriate for vacuum_cleanup_index_scale_factor, because vacuum_*_age options are already located there. Also, vacuum_cleanup_index_scale_factor was missed in postgresql.conf.sample. So, add it there with appropriate comment. Author: Masahiko Sawada with minor editorization by me Discussion: https://postgr.es/m/CAD21AoArsoXMLKudXSKN679FRzs6oubEchM53bHwn8Tp%3D2boNg%40mail.gmail.com
Diffstat (limited to 'src')
-rw-r--r--src/backend/utils/misc/guc.c2
-rw-r--r--src/backend/utils/misc/postgresql.conf.sample3
2 files changed, 4 insertions, 1 deletions
diff --git a/src/backend/utils/misc/guc.c b/src/backend/utils/misc/guc.c
index fa3c8a79050..859ef931e71 100644
--- a/src/backend/utils/misc/guc.c
+++ b/src/backend/utils/misc/guc.c
@@ -3248,7 +3248,7 @@ static struct config_real ConfigureNamesReal[] =
},
{
- {"vacuum_cleanup_index_scale_factor", PGC_USERSET, AUTOVACUUM,
+ {"vacuum_cleanup_index_scale_factor", PGC_USERSET, CLIENT_CONN_STATEMENT,
gettext_noop("Number of tuple inserts prior to index cleanup as a fraction of reltuples."),
NULL
},
diff --git a/src/backend/utils/misc/postgresql.conf.sample b/src/backend/utils/misc/postgresql.conf.sample
index f43086f6d06..9e39baf4668 100644
--- a/src/backend/utils/misc/postgresql.conf.sample
+++ b/src/backend/utils/misc/postgresql.conf.sample
@@ -575,6 +575,9 @@
#vacuum_freeze_table_age = 150000000
#vacuum_multixact_freeze_min_age = 5000000
#vacuum_multixact_freeze_table_age = 150000000
+#vacuum_cleanup_index_scale_factor = 0.1 # fraction of total number of tuples
+ # before index cleanup, 0 always performs
+ # index cleanup
#bytea_output = 'hex' # hex, escape
#xmlbinary = 'base64'
#xmloption = 'content'