Thanks to visit codestin.com
Credit goes to doxygen.postgresql.org

PostgreSQL Source Code git master
guc_tables.c
Go to the documentation of this file.
1/*--------------------------------------------------------------------
2 *
3 * guc_tables.c
4 *
5 * Static tables for the Grand Unified Configuration scheme.
6 *
7 * Many of these tables are const. However, ConfigureNamesBool[]
8 * and so on are not, because the structs in those arrays are actually
9 * the live per-variable state data that guc.c manipulates. While many of
10 * their fields are intended to be constant, some fields change at runtime.
11 *
12 *
13 * Copyright (c) 2000-2025, PostgreSQL Global Development Group
14 * Written by Peter Eisentraut <[email protected]>.
15 *
16 * IDENTIFICATION
17 * src/backend/utils/misc/guc_tables.c
18 *
19 *--------------------------------------------------------------------
20 */
21#include "postgres.h"
22
23#ifdef HAVE_COPYFILE_H
24#include <copyfile.h>
25#endif
26#include <float.h>
27#include <limits.h>
28#ifdef HAVE_SYSLOG
29#include <syslog.h>
30#endif
31
32#include "access/commit_ts.h"
33#include "access/gin.h"
34#include "access/slru.h"
36#include "access/twophase.h"
39#include "access/xlogrecovery.h"
40#include "access/xlogutils.h"
42#include "catalog/namespace.h"
43#include "catalog/storage.h"
44#include "commands/async.h"
45#include "commands/extension.h"
47#include "commands/tablespace.h"
48#include "commands/trigger.h"
49#include "commands/user.h"
50#include "commands/vacuum.h"
51#include "common/file_utils.h"
52#include "common/scram-common.h"
53#include "jit/jit.h"
54#include "libpq/auth.h"
55#include "libpq/libpq.h"
56#include "libpq/oauth.h"
57#include "libpq/scram.h"
58#include "nodes/queryjumble.h"
59#include "optimizer/cost.h"
60#include "optimizer/geqo.h"
61#include "optimizer/optimizer.h"
62#include "optimizer/paths.h"
63#include "optimizer/planmain.h"
64#include "parser/parse_expr.h"
65#include "parser/parser.h"
66#include "pgstat.h"
69#include "postmaster/bgwriter.h"
71#include "postmaster/startup.h"
76#include "replication/slot.h"
78#include "replication/syncrep.h"
79#include "storage/aio.h"
80#include "storage/bufmgr.h"
81#include "storage/bufpage.h"
82#include "storage/copydir.h"
83#include "storage/io_worker.h"
85#include "storage/pg_shmem.h"
86#include "storage/predicate.h"
87#include "storage/procnumber.h"
88#include "storage/standby.h"
90#include "tcop/tcopprot.h"
91#include "tsearch/ts_cache.h"
92#include "utils/builtins.h"
93#include "utils/bytea.h"
94#include "utils/float.h"
95#include "utils/guc_hooks.h"
96#include "utils/guc_tables.h"
97#include "utils/inval.h"
98#include "utils/memutils.h"
99#include "utils/pg_locale.h"
100#include "utils/plancache.h"
101#include "utils/ps_status.h"
102#include "utils/rls.h"
103#include "utils/xml.h"
104
105#ifdef TRACE_SYNCSCAN
106#include "access/syncscan.h"
107#endif
108
109/* This value is normally passed in from the Makefile */
110#ifndef PG_KRB_SRVTAB
111#define PG_KRB_SRVTAB ""
112#endif
113
114/*
115 * Options for enum values defined in this module.
116 *
117 * NOTE! Option values may not contain double quotes!
118 */
119
121 {"escape", BYTEA_OUTPUT_ESCAPE, false},
122 {"hex", BYTEA_OUTPUT_HEX, false},
123 {NULL, 0, false}
124};
125
127 "array length mismatch");
128
129/*
130 * We have different sets for client and server message level options because
131 * they sort slightly different (see "log" level), and because "fatal"/"panic"
132 * aren't sensible for client_min_messages.
133 */
135 {"debug5", DEBUG5, false},
136 {"debug4", DEBUG4, false},
137 {"debug3", DEBUG3, false},
138 {"debug2", DEBUG2, false},
139 {"debug1", DEBUG1, false},
140 {"debug", DEBUG2, true},
141 {"log", LOG, false},
142 {"info", INFO, true},
143 {"notice", NOTICE, false},
144 {"warning", WARNING, false},
145 {"error", ERROR, false},
146 {NULL, 0, false}
147};
148
150 {"debug5", DEBUG5, false},
151 {"debug4", DEBUG4, false},
152 {"debug3", DEBUG3, false},
153 {"debug2", DEBUG2, false},
154 {"debug1", DEBUG1, false},
155 {"debug", DEBUG2, true},
156 {"info", INFO, false},
157 {"notice", NOTICE, false},
158 {"warning", WARNING, false},
159 {"error", ERROR, false},
160 {"log", LOG, false},
161 {"fatal", FATAL, false},
162 {"panic", PANIC, false},
163 {NULL, 0, false}
164};
165
167 {"postgres", INTSTYLE_POSTGRES, false},
168 {"postgres_verbose", INTSTYLE_POSTGRES_VERBOSE, false},
169 {"sql_standard", INTSTYLE_SQL_STANDARD, false},
170 {"iso_8601", INTSTYLE_ISO_8601, false},
171 {NULL, 0, false}
172};
173
175 {"disabled", -1, false},
176 {"debug5", DEBUG5, false},
177 {"debug4", DEBUG4, false},
178 {"debug3", DEBUG3, false},
179 {"debug2", DEBUG2, false},
180 {"debug1", DEBUG1, false},
181 {"debug", DEBUG2, true},
182 {"log", LOG, false},
183 {"info", INFO, true},
184 {"notice", NOTICE, false},
185 {"warning", WARNING, false},
186 {"error", ERROR, false},
187 {NULL, 0, false}
188};
189
191 "array length mismatch");
192
194 {"terse", PGERROR_TERSE, false},
195 {"default", PGERROR_DEFAULT, false},
196 {"verbose", PGERROR_VERBOSE, false},
197 {NULL, 0, false}
198};
199
201 "array length mismatch");
202
204 {"none", LOGSTMT_NONE, false},
205 {"ddl", LOGSTMT_DDL, false},
206 {"mod", LOGSTMT_MOD, false},
207 {"all", LOGSTMT_ALL, false},
208 {NULL, 0, false}
209};
210
212 "array length mismatch");
213
215 {"serializable", XACT_SERIALIZABLE, false},
216 {"repeatable read", XACT_REPEATABLE_READ, false},
217 {"read committed", XACT_READ_COMMITTED, false},
218 {"read uncommitted", XACT_READ_UNCOMMITTED, false},
219 {NULL, 0}
220};
221
223 {"origin", SESSION_REPLICATION_ROLE_ORIGIN, false},
224 {"replica", SESSION_REPLICATION_ROLE_REPLICA, false},
225 {"local", SESSION_REPLICATION_ROLE_LOCAL, false},
226 {NULL, 0, false}
227};
228
230 "array length mismatch");
231
233#ifdef HAVE_SYSLOG
234 {"local0", LOG_LOCAL0, false},
235 {"local1", LOG_LOCAL1, false},
236 {"local2", LOG_LOCAL2, false},
237 {"local3", LOG_LOCAL3, false},
238 {"local4", LOG_LOCAL4, false},
239 {"local5", LOG_LOCAL5, false},
240 {"local6", LOG_LOCAL6, false},
241 {"local7", LOG_LOCAL7, false},
242#else
243 {"none", 0, false},
244#endif
245 {NULL, 0}
246};
247
249 {"none", TRACK_FUNC_OFF, false},
250 {"pl", TRACK_FUNC_PL, false},
251 {"all", TRACK_FUNC_ALL, false},
252 {NULL, 0, false}
253};
254
256 "array length mismatch");
257
259 {"none", PGSTAT_FETCH_CONSISTENCY_NONE, false},
260 {"cache", PGSTAT_FETCH_CONSISTENCY_CACHE, false},
261 {"snapshot", PGSTAT_FETCH_CONSISTENCY_SNAPSHOT, false},
262 {NULL, 0, false}
263};
264
266 "array length mismatch");
267
268static const struct config_enum_entry xmlbinary_options[] = {
269 {"base64", XMLBINARY_BASE64, false},
270 {"hex", XMLBINARY_HEX, false},
271 {NULL, 0, false}
272};
273
275 "array length mismatch");
276
277static const struct config_enum_entry xmloption_options[] = {
278 {"content", XMLOPTION_CONTENT, false},
279 {"document", XMLOPTION_DOCUMENT, false},
280 {NULL, 0, false}
281};
282
284 "array length mismatch");
285
286/*
287 * Although only "on", "off", and "safe_encoding" are documented, we
288 * accept all the likely variants of "on" and "off".
289 */
291 {"safe_encoding", BACKSLASH_QUOTE_SAFE_ENCODING, false},
292 {"on", BACKSLASH_QUOTE_ON, false},
293 {"off", BACKSLASH_QUOTE_OFF, false},
294 {"true", BACKSLASH_QUOTE_ON, true},
295 {"false", BACKSLASH_QUOTE_OFF, true},
296 {"yes", BACKSLASH_QUOTE_ON, true},
297 {"no", BACKSLASH_QUOTE_OFF, true},
298 {"1", BACKSLASH_QUOTE_ON, true},
299 {"0", BACKSLASH_QUOTE_OFF, true},
300 {NULL, 0, false}
301};
302
303/*
304 * Although only "on", "off", and "auto" are documented, we accept
305 * all the likely variants of "on" and "off".
306 */
308 {"auto", COMPUTE_QUERY_ID_AUTO, false},
309 {"regress", COMPUTE_QUERY_ID_REGRESS, false},
310 {"on", COMPUTE_QUERY_ID_ON, false},
311 {"off", COMPUTE_QUERY_ID_OFF, false},
312 {"true", COMPUTE_QUERY_ID_ON, true},
313 {"false", COMPUTE_QUERY_ID_OFF, true},
314 {"yes", COMPUTE_QUERY_ID_ON, true},
315 {"no", COMPUTE_QUERY_ID_OFF, true},
316 {"1", COMPUTE_QUERY_ID_ON, true},
317 {"0", COMPUTE_QUERY_ID_OFF, true},
318 {NULL, 0, false}
319};
320
321/*
322 * Although only "on", "off", and "partition" are documented, we
323 * accept all the likely variants of "on" and "off".
324 */
326 {"partition", CONSTRAINT_EXCLUSION_PARTITION, false},
327 {"on", CONSTRAINT_EXCLUSION_ON, false},
328 {"off", CONSTRAINT_EXCLUSION_OFF, false},
329 {"true", CONSTRAINT_EXCLUSION_ON, true},
330 {"false", CONSTRAINT_EXCLUSION_OFF, true},
331 {"yes", CONSTRAINT_EXCLUSION_ON, true},
332 {"no", CONSTRAINT_EXCLUSION_OFF, true},
333 {"1", CONSTRAINT_EXCLUSION_ON, true},
334 {"0", CONSTRAINT_EXCLUSION_OFF, true},
335 {NULL, 0, false}
336};
337
338/*
339 * Although only "on", "off", "remote_apply", "remote_write", and "local" are
340 * documented, we accept all the likely variants of "on" and "off".
341 */
343 {"local", SYNCHRONOUS_COMMIT_LOCAL_FLUSH, false},
344 {"remote_write", SYNCHRONOUS_COMMIT_REMOTE_WRITE, false},
345 {"remote_apply", SYNCHRONOUS_COMMIT_REMOTE_APPLY, false},
346 {"on", SYNCHRONOUS_COMMIT_ON, false},
347 {"off", SYNCHRONOUS_COMMIT_OFF, false},
348 {"true", SYNCHRONOUS_COMMIT_ON, true},
349 {"false", SYNCHRONOUS_COMMIT_OFF, true},
350 {"yes", SYNCHRONOUS_COMMIT_ON, true},
351 {"no", SYNCHRONOUS_COMMIT_OFF, true},
352 {"1", SYNCHRONOUS_COMMIT_ON, true},
353 {"0", SYNCHRONOUS_COMMIT_OFF, true},
354 {NULL, 0, false}
355};
356
357/*
358 * Although only "on", "off", "try" are documented, we accept all the likely
359 * variants of "on" and "off".
360 */
361static const struct config_enum_entry huge_pages_options[] = {
362 {"off", HUGE_PAGES_OFF, false},
363 {"on", HUGE_PAGES_ON, false},
364 {"try", HUGE_PAGES_TRY, false},
365 {"true", HUGE_PAGES_ON, true},
366 {"false", HUGE_PAGES_OFF, true},
367 {"yes", HUGE_PAGES_ON, true},
368 {"no", HUGE_PAGES_OFF, true},
369 {"1", HUGE_PAGES_ON, true},
370 {"0", HUGE_PAGES_OFF, true},
371 {NULL, 0, false}
372};
373
375 {"off", HUGE_PAGES_OFF, false},
376 {"on", HUGE_PAGES_ON, false},
377 {"unknown", HUGE_PAGES_UNKNOWN, false},
378 {NULL, 0, false}
379};
380
382 {"off", RECOVERY_PREFETCH_OFF, false},
383 {"on", RECOVERY_PREFETCH_ON, false},
384 {"try", RECOVERY_PREFETCH_TRY, false},
385 {"true", RECOVERY_PREFETCH_ON, true},
386 {"false", RECOVERY_PREFETCH_OFF, true},
387 {"yes", RECOVERY_PREFETCH_ON, true},
388 {"no", RECOVERY_PREFETCH_OFF, true},
389 {"1", RECOVERY_PREFETCH_ON, true},
390 {"0", RECOVERY_PREFETCH_OFF, true},
391 {NULL, 0, false}
392};
393
395 {"off", DEBUG_PARALLEL_OFF, false},
396 {"on", DEBUG_PARALLEL_ON, false},
397 {"regress", DEBUG_PARALLEL_REGRESS, false},
398 {"true", DEBUG_PARALLEL_ON, true},
399 {"false", DEBUG_PARALLEL_OFF, true},
400 {"yes", DEBUG_PARALLEL_ON, true},
401 {"no", DEBUG_PARALLEL_OFF, true},
402 {"1", DEBUG_PARALLEL_ON, true},
403 {"0", DEBUG_PARALLEL_OFF, true},
404 {NULL, 0, false}
405};
406
408 {"auto", PLAN_CACHE_MODE_AUTO, false},
409 {"force_generic_plan", PLAN_CACHE_MODE_FORCE_GENERIC_PLAN, false},
410 {"force_custom_plan", PLAN_CACHE_MODE_FORCE_CUSTOM_PLAN, false},
411 {NULL, 0, false}
412};
413
415 {"md5", PASSWORD_TYPE_MD5, false},
416 {"scram-sha-256", PASSWORD_TYPE_SCRAM_SHA_256, false},
417 {NULL, 0, false}
418};
419
421 {"", PG_TLS_ANY, false},
422 {"TLSv1", PG_TLS1_VERSION, false},
423 {"TLSv1.1", PG_TLS1_1_VERSION, false},
424 {"TLSv1.2", PG_TLS1_2_VERSION, false},
425 {"TLSv1.3", PG_TLS1_3_VERSION, false},
426 {NULL, 0, false}
427};
428
430 {"buffered", DEBUG_LOGICAL_REP_STREAMING_BUFFERED, false},
431 {"immediate", DEBUG_LOGICAL_REP_STREAMING_IMMEDIATE, false},
432 {NULL, 0, false}
433};
434
436 "array length mismatch");
437
439 {"fsync", DATA_DIR_SYNC_METHOD_FSYNC, false},
440#ifdef HAVE_SYNCFS
441 {"syncfs", DATA_DIR_SYNC_METHOD_SYNCFS, false},
442#endif
443 {NULL, 0, false}
444};
445
447#ifndef WIN32
448 {"sysv", SHMEM_TYPE_SYSV, false},
449#endif
450#ifndef EXEC_BACKEND
451 {"mmap", SHMEM_TYPE_MMAP, false},
452#endif
453#ifdef WIN32
454 {"windows", SHMEM_TYPE_WINDOWS, false},
455#endif
456 {NULL, 0, false}
457};
458
460 {"pglz", TOAST_PGLZ_COMPRESSION, false},
461#ifdef USE_LZ4
462 {"lz4", TOAST_LZ4_COMPRESSION, false},
463#endif
464 {NULL, 0, false}
465};
466
468 {"pglz", WAL_COMPRESSION_PGLZ, false},
469#ifdef USE_LZ4
470 {"lz4", WAL_COMPRESSION_LZ4, false},
471#endif
472#ifdef USE_ZSTD
473 {"zstd", WAL_COMPRESSION_ZSTD, false},
474#endif
475 {"on", WAL_COMPRESSION_PGLZ, false},
476 {"off", WAL_COMPRESSION_NONE, false},
477 {"true", WAL_COMPRESSION_PGLZ, true},
478 {"false", WAL_COMPRESSION_NONE, true},
479 {"yes", WAL_COMPRESSION_PGLZ, true},
480 {"no", WAL_COMPRESSION_NONE, true},
481 {"1", WAL_COMPRESSION_PGLZ, true},
482 {"0", WAL_COMPRESSION_NONE, true},
483 {NULL, 0, false}
484};
485
487 {"copy", FILE_COPY_METHOD_COPY, false},
488#if defined(HAVE_COPYFILE) && defined(COPYFILE_CLONE_FORCE) || defined(HAVE_COPY_FILE_RANGE)
489 {"clone", FILE_COPY_METHOD_CLONE, false},
490#endif
491 {NULL, 0, false}
492};
493
494/*
495 * Options for enum values stored in other modules
496 */
497extern const struct config_enum_entry wal_level_options[];
498extern const struct config_enum_entry archive_mode_options[];
500extern const struct config_enum_entry wal_sync_method_options[];
502
503/*
504 * GUC option variables that are exported from this module
505 */
507bool log_duration = false;
508bool Debug_print_plan = false;
509bool Debug_print_parse = false;
513
514#ifdef DEBUG_NODE_TESTS_ENABLED
515bool Debug_copy_parse_plan_trees;
516bool Debug_write_read_parse_plan_trees;
517bool Debug_raw_expression_coverage_test;
518#endif
519
520bool log_parser_stats = false;
521bool log_planner_stats = false;
523bool log_statement_stats = false; /* this is sort of all three above
524 * together */
527
530
531/*
532 * This GUC exists solely for backward compatibility, check its definition for
533 * details.
534 */
535static bool default_with_oids = false;
536
538
550
552
554
555char *cluster_name = "";
560
562
567
568/*
569 * SSL renegotiation was been removed in PostgreSQL 9.5, but we tolerate it
570 * being set to zero (meaning never renegotiate) for backward compatibility.
571 * This avoids breaking compatibility with clients that have never supported
572 * renegotiation and therefore always try to zero it.
573 */
575
576/*
577 * This really belongs in pg_shmem.c, but is defined here so that it doesn't
578 * need to be duplicated in all the different implementations of pg_shmem.c.
579 */
583
584/*
585 * These variables are all dummies that don't do anything, except in some
586 * cases provide the value for SHOW to display. The real state is elsewhere
587 * and is kept in sync by assign_hooks.
588 */
589static char *syslog_ident_str;
590static double phony_random_seed;
592static char *datestyle_string;
598
599#ifdef HAVE_SYSLOG
600#define DEFAULT_SYSLOG_FACILITY LOG_LOCAL0
601#else
602#define DEFAULT_SYSLOG_FACILITY 0
603#endif
605
606static char *timezone_string;
609static char *data_directory;
612static int max_index_keys;
614static int block_size;
615static int segment_size;
618static int wal_block_size;
620static bool data_checksums;
622
623#ifdef USE_ASSERT_CHECKING
624#define DEFAULT_ASSERT_ENABLED true
625#else
626#define DEFAULT_ASSERT_ENABLED false
627#endif
629
635
636/* should be static, but commands/variable.c needs to get at this */
638
639/* should be static, but guc.c needs to get at this */
641
642
643/*
644 * Displayable names for context types (enum GucContext)
645 *
646 * Note: these strings are deliberately not localized.
647 */
648const char *const GucContext_Names[] =
649{
650 [PGC_INTERNAL] = "internal",
651 [PGC_POSTMASTER] = "postmaster",
652 [PGC_SIGHUP] = "sighup",
653 [PGC_SU_BACKEND] = "superuser-backend",
654 [PGC_BACKEND] = "backend",
655 [PGC_SUSET] = "superuser",
656 [PGC_USERSET] = "user",
657};
658
660 "array length mismatch");
661
662/*
663 * Displayable names for source types (enum GucSource)
664 *
665 * Note: these strings are deliberately not localized.
666 */
667const char *const GucSource_Names[] =
668{
669 [PGC_S_DEFAULT] = "default",
670 [PGC_S_DYNAMIC_DEFAULT] = "default",
671 [PGC_S_ENV_VAR] = "environment variable",
672 [PGC_S_FILE] = "configuration file",
673 [PGC_S_ARGV] = "command line",
674 [PGC_S_GLOBAL] = "global",
675 [PGC_S_DATABASE] = "database",
676 [PGC_S_USER] = "user",
677 [PGC_S_DATABASE_USER] = "database user",
678 [PGC_S_CLIENT] = "client",
679 [PGC_S_OVERRIDE] = "override",
680 [PGC_S_INTERACTIVE] = "interactive",
681 [PGC_S_TEST] = "test",
682 [PGC_S_SESSION] = "session",
683};
684
686 "array length mismatch");
687
688/*
689 * Displayable names for the groupings defined in enum config_group
690 */
691const char *const config_group_names[] =
692{
693 [UNGROUPED] = gettext_noop("Ungrouped"),
694 [FILE_LOCATIONS] = gettext_noop("File Locations"),
695 [CONN_AUTH_SETTINGS] = gettext_noop("Connections and Authentication / Connection Settings"),
696 [CONN_AUTH_TCP] = gettext_noop("Connections and Authentication / TCP Settings"),
697 [CONN_AUTH_AUTH] = gettext_noop("Connections and Authentication / Authentication"),
698 [CONN_AUTH_SSL] = gettext_noop("Connections and Authentication / SSL"),
699 [RESOURCES_MEM] = gettext_noop("Resource Usage / Memory"),
700 [RESOURCES_DISK] = gettext_noop("Resource Usage / Disk"),
701 [RESOURCES_KERNEL] = gettext_noop("Resource Usage / Kernel Resources"),
702 [RESOURCES_BGWRITER] = gettext_noop("Resource Usage / Background Writer"),
703 [RESOURCES_IO] = gettext_noop("Resource Usage / I/O"),
704 [RESOURCES_WORKER_PROCESSES] = gettext_noop("Resource Usage / Worker Processes"),
705 [WAL_SETTINGS] = gettext_noop("Write-Ahead Log / Settings"),
706 [WAL_CHECKPOINTS] = gettext_noop("Write-Ahead Log / Checkpoints"),
707 [WAL_ARCHIVING] = gettext_noop("Write-Ahead Log / Archiving"),
708 [WAL_RECOVERY] = gettext_noop("Write-Ahead Log / Recovery"),
709 [WAL_ARCHIVE_RECOVERY] = gettext_noop("Write-Ahead Log / Archive Recovery"),
710 [WAL_RECOVERY_TARGET] = gettext_noop("Write-Ahead Log / Recovery Target"),
711 [WAL_SUMMARIZATION] = gettext_noop("Write-Ahead Log / Summarization"),
712 [REPLICATION_SENDING] = gettext_noop("Replication / Sending Servers"),
713 [REPLICATION_PRIMARY] = gettext_noop("Replication / Primary Server"),
714 [REPLICATION_STANDBY] = gettext_noop("Replication / Standby Servers"),
715 [REPLICATION_SUBSCRIBERS] = gettext_noop("Replication / Subscribers"),
716 [QUERY_TUNING_METHOD] = gettext_noop("Query Tuning / Planner Method Configuration"),
717 [QUERY_TUNING_COST] = gettext_noop("Query Tuning / Planner Cost Constants"),
718 [QUERY_TUNING_GEQO] = gettext_noop("Query Tuning / Genetic Query Optimizer"),
719 [QUERY_TUNING_OTHER] = gettext_noop("Query Tuning / Other Planner Options"),
720 [LOGGING_WHERE] = gettext_noop("Reporting and Logging / Where to Log"),
721 [LOGGING_WHEN] = gettext_noop("Reporting and Logging / When to Log"),
722 [LOGGING_WHAT] = gettext_noop("Reporting and Logging / What to Log"),
723 [PROCESS_TITLE] = gettext_noop("Reporting and Logging / Process Title"),
724 [STATS_MONITORING] = gettext_noop("Statistics / Monitoring"),
725 [STATS_CUMULATIVE] = gettext_noop("Statistics / Cumulative Query and Index Statistics"),
726 [VACUUM_AUTOVACUUM] = gettext_noop("Vacuuming / Automatic Vacuuming"),
727 [VACUUM_COST_DELAY] = gettext_noop("Vacuuming / Cost-Based Vacuum Delay"),
728 [VACUUM_DEFAULT] = gettext_noop("Vacuuming / Default Behavior"),
729 [VACUUM_FREEZING] = gettext_noop("Vacuuming / Freezing"),
730 [CLIENT_CONN_STATEMENT] = gettext_noop("Client Connection Defaults / Statement Behavior"),
731 [CLIENT_CONN_LOCALE] = gettext_noop("Client Connection Defaults / Locale and Formatting"),
732 [CLIENT_CONN_PRELOAD] = gettext_noop("Client Connection Defaults / Shared Library Preloading"),
733 [CLIENT_CONN_OTHER] = gettext_noop("Client Connection Defaults / Other Defaults"),
734 [LOCK_MANAGEMENT] = gettext_noop("Lock Management"),
735 [COMPAT_OPTIONS_PREVIOUS] = gettext_noop("Version and Platform Compatibility / Previous PostgreSQL Versions"),
736 [COMPAT_OPTIONS_OTHER] = gettext_noop("Version and Platform Compatibility / Other Platforms and Clients"),
737 [ERROR_HANDLING_OPTIONS] = gettext_noop("Error Handling"),
738 [PRESET_OPTIONS] = gettext_noop("Preset Options"),
739 [CUSTOM_OPTIONS] = gettext_noop("Customized Options"),
740 [DEVELOPER_OPTIONS] = gettext_noop("Developer Options"),
741};
742
744 "array length mismatch");
745
746/*
747 * Displayable names for GUC variable types (enum config_type)
748 *
749 * Note: these strings are deliberately not localized.
750 */
751const char *const config_type_names[] =
752{
753 [PGC_BOOL] = "bool",
754 [PGC_INT] = "integer",
755 [PGC_REAL] = "real",
756 [PGC_STRING] = "string",
757 [PGC_ENUM] = "enum",
758};
759
761 "array length mismatch");
762
763
764#include "utils/guc_tables.inc.c"
@ BYTEA_OUTPUT_HEX
Definition: bytea.h:22
@ BYTEA_OUTPUT_ESCAPE
Definition: bytea.h:21
#define gettext_noop(x)
Definition: c.h:1196
#define lengthof(array)
Definition: c.h:788
@ FILE_COPY_METHOD_COPY
Definition: copydir.h:18
@ FILE_COPY_METHOD_CLONE
Definition: copydir.h:19
@ CONSTRAINT_EXCLUSION_OFF
Definition: cost.h:38
@ CONSTRAINT_EXCLUSION_PARTITION
Definition: cost.h:40
@ CONSTRAINT_EXCLUSION_ON
Definition: cost.h:39
@ PASSWORD_TYPE_SCRAM_SHA_256
Definition: crypt.h:44
@ PASSWORD_TYPE_MD5
Definition: crypt.h:43
@ PGERROR_VERBOSE
Definition: elog.h:474
@ PGERROR_DEFAULT
Definition: elog.h:473
@ PGERROR_TERSE
Definition: elog.h:472
#define LOG
Definition: elog.h:31
#define DEBUG3
Definition: elog.h:28
#define FATAL
Definition: elog.h:41
#define WARNING
Definition: elog.h:36
#define DEBUG2
Definition: elog.h:29
#define PANIC
Definition: elog.h:42
#define DEBUG1
Definition: elog.h:30
#define ERROR
Definition: elog.h:39
#define NOTICE
Definition: elog.h:35
#define INFO
Definition: elog.h:34
#define DEBUG5
Definition: elog.h:26
#define DEBUG4
Definition: elog.h:27
@ DATA_DIR_SYNC_METHOD_SYNCFS
Definition: file_utils.h:30
@ DATA_DIR_SYNC_METHOD_FSYNC
Definition: file_utils.h:29
@ PGC_S_DEFAULT
Definition: guc.h:113
@ PGC_S_DYNAMIC_DEFAULT
Definition: guc.h:114
@ PGC_S_FILE
Definition: guc.h:116
@ PGC_S_GLOBAL
Definition: guc.h:118
@ PGC_S_DATABASE
Definition: guc.h:119
@ PGC_S_OVERRIDE
Definition: guc.h:123
@ PGC_S_ARGV
Definition: guc.h:117
@ PGC_S_SESSION
Definition: guc.h:126
@ PGC_S_CLIENT
Definition: guc.h:122
@ PGC_S_DATABASE_USER
Definition: guc.h:121
@ PGC_S_ENV_VAR
Definition: guc.h:115
@ PGC_S_USER
Definition: guc.h:120
@ PGC_S_TEST
Definition: guc.h:125
@ PGC_S_INTERACTIVE
Definition: guc.h:124
@ PGC_SUSET
Definition: guc.h:78
@ PGC_INTERNAL
Definition: guc.h:73
@ PGC_USERSET
Definition: guc.h:79
@ PGC_SU_BACKEND
Definition: guc.h:76
@ PGC_POSTMASTER
Definition: guc.h:74
@ PGC_SIGHUP
Definition: guc.h:75
@ PGC_BACKEND
Definition: guc.h:77
static char * recovery_target_lsn_string
Definition: guc_tables.c:634
bool log_statement_stats
Definition: guc_tables.c:523
static char * client_encoding_string
Definition: guc_tables.c:591
static int segment_size
Definition: guc_tables.c:615
static char * timezone_abbreviations_string
Definition: guc_tables.c:608
static const struct config_enum_entry stats_fetch_consistency[]
Definition: guc_tables.c:258
bool Debug_print_plan
Definition: guc_tables.c:508
char * event_source
Definition: guc_tables.c:526
bool check_function_bodies
Definition: guc_tables.c:529
int num_temp_buffers
Definition: guc_tables.c:553
int client_min_messages
Definition: guc_tables.c:541
static int max_identifier_length
Definition: guc_tables.c:613
static const struct config_enum_entry password_encryption_options[]
Definition: guc_tables.c:414
static const struct config_enum_entry ssl_protocol_versions_info[]
Definition: guc_tables.c:420
const struct config_enum_entry recovery_target_action_options[]
Definition: xlogrecovery.c:76
static bool default_with_oids
Definition: guc_tables.c:535
bool Debug_print_raw_parse
Definition: guc_tables.c:510
static char * timezone_string
Definition: guc_tables.c:606
static const struct config_enum_entry debug_parallel_query_options[]
Definition: guc_tables.c:394
static char * server_version_string
Definition: guc_tables.c:594
int log_min_error_statement
Definition: guc_tables.c:539
static bool data_checksums
Definition: guc_tables.c:620
static const struct config_enum_entry file_copy_method_options[]
Definition: guc_tables.c:486
static const struct config_enum_entry syslog_facility_options[]
Definition: guc_tables.c:232
static const struct config_enum_entry icu_validation_level_options[]
Definition: guc_tables.c:174
static const struct config_enum_entry recovery_prefetch_options[]
Definition: guc_tables.c:381
static const struct config_enum_entry recovery_init_sync_method_options[]
Definition: guc_tables.c:438
int tcp_keepalives_idle
Definition: guc_tables.c:563
char * HbaFileName
Definition: guc_tables.c:557
int temp_file_limit
Definition: guc_tables.c:551
const char *const GucContext_Names[]
Definition: guc_tables.c:648
static int ssl_renegotiation_limit
Definition: guc_tables.c:574
static int syslog_facility
Definition: guc_tables.c:604
static int max_function_args
Definition: guc_tables.c:611
int tcp_keepalives_interval
Definition: guc_tables.c:564
static int max_index_keys
Definition: guc_tables.c:612
static const struct config_enum_entry backslash_quote_options[]
Definition: guc_tables.c:290
static char * syslog_ident_str
Definition: guc_tables.c:589
#define DEFAULT_SYSLOG_FACILITY
Definition: guc_tables.c:602
const char *const GucSource_Names[]
Definition: guc_tables.c:667
char * ConfigFileName
Definition: guc_tables.c:556
bool log_parser_stats
Definition: guc_tables.c:520
static int block_size
Definition: guc_tables.c:614
int tcp_keepalives_count
Definition: guc_tables.c:565
double log_xact_sample_rate
Definition: guc_tables.c:548
#define DEFAULT_ASSERT_ENABLED
Definition: guc_tables.c:626
static const struct config_enum_entry shared_memory_options[]
Definition: guc_tables.c:446
static const struct config_enum_entry huge_pages_status_options[]
Definition: guc_tables.c:374
const char *const config_type_names[]
Definition: guc_tables.c:751
bool Debug_pretty_print
Definition: guc_tables.c:512
char * role_string
Definition: guc_tables.c:637
static char * server_encoding_string
Definition: guc_tables.c:593
static int wal_block_size
Definition: guc_tables.c:618
static const struct config_enum_entry log_statement_options[]
Definition: guc_tables.c:203
static const struct config_enum_entry plan_cache_mode_options[]
Definition: guc_tables.c:407
int huge_pages
Definition: guc_tables.c:580
static const struct config_enum_entry wal_compression_options[]
Definition: guc_tables.c:467
static const struct config_enum_entry debug_logical_replication_streaming_options[]
Definition: guc_tables.c:429
static char * datestyle_string
Definition: guc_tables.c:592
static char * recovery_target_timeline_string
Definition: guc_tables.c:630
static char * restrict_nonsystem_relation_kind_string
Definition: guc_tables.c:597
int log_parameter_max_length_on_error
Definition: guc_tables.c:545
const struct config_enum_entry dynamic_shared_memory_options[]
Definition: dsm_impl.c:95
static const struct config_enum_entry xmlbinary_options[]
Definition: guc_tables.c:268
int log_min_duration_statement
Definition: guc_tables.c:543
static char * recovery_target_xid_string
Definition: guc_tables.c:632
bool AllowAlterSystem
Definition: guc_tables.c:506
int log_min_duration_sample
Definition: guc_tables.c:542
bool log_btree_build_stats
Definition: guc_tables.c:525
bool log_planner_stats
Definition: guc_tables.c:521
static const struct config_enum_entry bytea_output_options[]
Definition: guc_tables.c:120
bool row_security
Definition: guc_tables.c:528
const struct config_enum_entry archive_mode_options[]
Definition: xlog.c:192
static const struct config_enum_entry huge_pages_options[]
Definition: guc_tables.c:361
static const struct config_enum_entry synchronous_commit_options[]
Definition: guc_tables.c:342
static char * recovery_target_string
Definition: guc_tables.c:631
char * cluster_name
Definition: guc_tables.c:555
static bool assert_enabled
Definition: guc_tables.c:628
static const struct config_enum_entry default_toast_compression_options[]
Definition: guc_tables.c:459
static char * log_timezone_string
Definition: guc_tables.c:607
static char * session_authorization_string
Definition: guc_tables.c:610
bool in_hot_standby_guc
Definition: guc_tables.c:640
bool Debug_print_rewritten
Definition: guc_tables.c:511
static int shared_memory_size_in_huge_pages
Definition: guc_tables.c:617
static const struct config_enum_entry isolation_level_options[]
Definition: guc_tables.c:214
static const struct config_enum_entry log_error_verbosity_options[]
Definition: guc_tables.c:193
const struct config_enum_entry wal_sync_method_options[]
Definition: xlog.c:172
static int server_version_num
Definition: guc_tables.c:595
bool Debug_print_parse
Definition: guc_tables.c:509
char * application_name
Definition: guc_tables.c:561
static const struct config_enum_entry intervalstyle_options[]
Definition: guc_tables.c:166
int log_parameter_max_length
Definition: guc_tables.c:544
char * IdentFileName
Definition: guc_tables.c:558
const struct config_enum_entry wal_level_options[]
Definition: xlogdesc.c:27
static const struct config_enum_entry client_message_level_options[]
Definition: guc_tables.c:134
int tcp_user_timeout
Definition: guc_tables.c:566
bool current_role_is_superuser
Definition: guc_tables.c:537
static const struct config_enum_entry constraint_exclusion_options[]
Definition: guc_tables.c:325
static const struct config_enum_entry server_message_level_options[]
Definition: guc_tables.c:149
static const struct config_enum_entry compute_query_id_options[]
Definition: guc_tables.c:307
static char * recovery_target_name_string
Definition: guc_tables.c:633
int huge_page_size
Definition: guc_tables.c:581
static char * data_directory
Definition: guc_tables.c:609
StaticAssertDecl(lengthof(bytea_output_options)==(BYTEA_OUTPUT_HEX+2), "array length mismatch")
double log_statement_sample_rate
Definition: guc_tables.c:547
bool log_duration
Definition: guc_tables.c:507
const char *const config_group_names[]
Definition: guc_tables.c:691
static bool integer_datetimes
Definition: guc_tables.c:621
static double phony_random_seed
Definition: guc_tables.c:590
char * external_pid_file
Definition: guc_tables.c:559
int log_temp_files
Definition: guc_tables.c:546
static int num_os_semaphores
Definition: guc_tables.c:619
int log_min_messages
Definition: guc_tables.c:540
bool log_executor_stats
Definition: guc_tables.c:522
char * backtrace_functions
Definition: guc_tables.c:549
static int shared_memory_size_mb
Definition: guc_tables.c:616
static const struct config_enum_entry session_replication_role_options[]
Definition: guc_tables.c:222
static const struct config_enum_entry track_function_options[]
Definition: guc_tables.c:248
static const struct config_enum_entry xmloption_options[]
Definition: guc_tables.c:277
int huge_pages_status
Definition: guc_tables.c:582
static char * debug_io_direct_string
Definition: guc_tables.c:596
@ RESOURCES_KERNEL
Definition: guc_tables.h:65
@ CLIENT_CONN_LOCALE
Definition: guc_tables.h:95
@ WAL_ARCHIVE_RECOVERY
Definition: guc_tables.h:73
@ STATS_CUMULATIVE
Definition: guc_tables.h:89
@ CLIENT_CONN_PRELOAD
Definition: guc_tables.h:96
@ VACUUM_COST_DELAY
Definition: guc_tables.h:91
@ QUERY_TUNING_OTHER
Definition: guc_tables.h:83
@ LOGGING_WHERE
Definition: guc_tables.h:84
@ CONN_AUTH_AUTH
Definition: guc_tables.h:61
@ RESOURCES_WORKER_PROCESSES
Definition: guc_tables.h:68
@ VACUUM_FREEZING
Definition: guc_tables.h:93
@ ERROR_HANDLING_OPTIONS
Definition: guc_tables.h:101
@ PROCESS_TITLE
Definition: guc_tables.h:87
@ RESOURCES_DISK
Definition: guc_tables.h:64
@ REPLICATION_SENDING
Definition: guc_tables.h:76
@ RESOURCES_IO
Definition: guc_tables.h:67
@ LOCK_MANAGEMENT
Definition: guc_tables.h:98
@ CUSTOM_OPTIONS
Definition: guc_tables.h:103
@ REPLICATION_PRIMARY
Definition: guc_tables.h:77
@ STATS_MONITORING
Definition: guc_tables.h:88
@ WAL_RECOVERY_TARGET
Definition: guc_tables.h:74
@ WAL_RECOVERY
Definition: guc_tables.h:72
@ CONN_AUTH_SSL
Definition: guc_tables.h:62
@ RESOURCES_MEM
Definition: guc_tables.h:63
@ RESOURCES_BGWRITER
Definition: guc_tables.h:66
@ PRESET_OPTIONS
Definition: guc_tables.h:102
@ DEVELOPER_OPTIONS
Definition: guc_tables.h:104
@ QUERY_TUNING_METHOD
Definition: guc_tables.h:80
@ LOGGING_WHAT
Definition: guc_tables.h:86
@ VACUUM_DEFAULT
Definition: guc_tables.h:92
@ QUERY_TUNING_GEQO
Definition: guc_tables.h:82
@ WAL_SETTINGS
Definition: guc_tables.h:69
@ COMPAT_OPTIONS_OTHER
Definition: guc_tables.h:100
@ CLIENT_CONN_STATEMENT
Definition: guc_tables.h:94
@ FILE_LOCATIONS
Definition: guc_tables.h:58
@ REPLICATION_STANDBY
Definition: guc_tables.h:78
@ QUERY_TUNING_COST
Definition: guc_tables.h:81
@ WAL_ARCHIVING
Definition: guc_tables.h:71
@ COMPAT_OPTIONS_PREVIOUS
Definition: guc_tables.h:99
@ WAL_CHECKPOINTS
Definition: guc_tables.h:70
@ CLIENT_CONN_OTHER
Definition: guc_tables.h:97
@ LOGGING_WHEN
Definition: guc_tables.h:85
@ CONN_AUTH_TCP
Definition: guc_tables.h:60
@ REPLICATION_SUBSCRIBERS
Definition: guc_tables.h:79
@ WAL_SUMMARIZATION
Definition: guc_tables.h:75
@ CONN_AUTH_SETTINGS
Definition: guc_tables.h:59
@ UNGROUPED
Definition: guc_tables.h:57
@ VACUUM_AUTOVACUUM
Definition: guc_tables.h:90
@ PGC_BOOL
Definition: guc_tables.h:25
@ PGC_STRING
Definition: guc_tables.h:28
@ PGC_ENUM
Definition: guc_tables.h:29
@ PGC_REAL
Definition: guc_tables.h:27
@ PGC_INT
Definition: guc_tables.h:26
@ PG_TLS1_VERSION
Definition: libpq.h:149
@ PG_TLS1_3_VERSION
Definition: libpq.h:152
@ PG_TLS1_1_VERSION
Definition: libpq.h:150
@ PG_TLS1_2_VERSION
Definition: libpq.h:151
@ PG_TLS_ANY
Definition: libpq.h:148
#define INTSTYLE_SQL_STANDARD
Definition: miscadmin.h:258
#define INTSTYLE_POSTGRES_VERBOSE
Definition: miscadmin.h:257
#define INTSTYLE_ISO_8601
Definition: miscadmin.h:259
#define INTSTYLE_POSTGRES
Definition: miscadmin.h:256
@ DEBUG_PARALLEL_REGRESS
Definition: optimizer.h:97
@ DEBUG_PARALLEL_ON
Definition: optimizer.h:96
@ DEBUG_PARALLEL_OFF
Definition: optimizer.h:95
@ BACKSLASH_QUOTE_ON
Definition: parser.h:51
@ BACKSLASH_QUOTE_SAFE_ENCODING
Definition: parser.h:52
@ BACKSLASH_QUOTE_OFF
Definition: parser.h:50
@ HUGE_PAGES_UNKNOWN
Definition: pg_shmem.h:56
@ HUGE_PAGES_ON
Definition: pg_shmem.h:54
@ HUGE_PAGES_OFF
Definition: pg_shmem.h:53
@ HUGE_PAGES_TRY
Definition: pg_shmem.h:55
@ SHMEM_TYPE_MMAP
Definition: pg_shmem.h:64
@ SHMEM_TYPE_SYSV
Definition: pg_shmem.h:63
@ SHMEM_TYPE_WINDOWS
Definition: pg_shmem.h:62
@ PGSTAT_FETCH_CONSISTENCY_NONE
Definition: pgstat.h:47
@ PGSTAT_FETCH_CONSISTENCY_CACHE
Definition: pgstat.h:48
@ PGSTAT_FETCH_CONSISTENCY_SNAPSHOT
Definition: pgstat.h:49
@ TRACK_FUNC_PL
Definition: pgstat.h:41
@ TRACK_FUNC_ALL
Definition: pgstat.h:42
@ TRACK_FUNC_OFF
Definition: pgstat.h:40
@ PLAN_CACHE_MODE_FORCE_CUSTOM_PLAN
Definition: plancache.h:35
@ PLAN_CACHE_MODE_FORCE_GENERIC_PLAN
Definition: plancache.h:34
@ PLAN_CACHE_MODE_AUTO
Definition: plancache.h:33
@ XMLOPTION_CONTENT
Definition: primnodes.h:1604
@ XMLOPTION_DOCUMENT
Definition: primnodes.h:1603
@ COMPUTE_QUERY_ID_AUTO
Definition: queryjumble.h:85
@ COMPUTE_QUERY_ID_REGRESS
Definition: queryjumble.h:86
@ COMPUTE_QUERY_ID_ON
Definition: queryjumble.h:84
@ COMPUTE_QUERY_ID_OFF
Definition: queryjumble.h:83
@ DEBUG_LOGICAL_REP_STREAMING_IMMEDIATE
Definition: reorderbuffer.h:34
@ DEBUG_LOGICAL_REP_STREAMING_BUFFERED
Definition: reorderbuffer.h:33
Definition: guc.h:174
@ LOGSTMT_NONE
Definition: tcopprot.h:33
@ LOGSTMT_MOD
Definition: tcopprot.h:35
@ LOGSTMT_DDL
Definition: tcopprot.h:34
@ LOGSTMT_ALL
Definition: tcopprot.h:36
#define TOAST_PGLZ_COMPRESSION
#define TOAST_LZ4_COMPRESSION
#define SESSION_REPLICATION_ROLE_REPLICA
Definition: trigger.h:141
#define SESSION_REPLICATION_ROLE_LOCAL
Definition: trigger.h:142
#define SESSION_REPLICATION_ROLE_ORIGIN
Definition: trigger.h:140
#define XACT_SERIALIZABLE
Definition: xact.h:39
@ SYNCHRONOUS_COMMIT_LOCAL_FLUSH
Definition: xact.h:72
@ SYNCHRONOUS_COMMIT_REMOTE_WRITE
Definition: xact.h:73
@ SYNCHRONOUS_COMMIT_REMOTE_APPLY
Definition: xact.h:76
@ SYNCHRONOUS_COMMIT_OFF
Definition: xact.h:71
#define SYNCHRONOUS_COMMIT_ON
Definition: xact.h:81
#define XACT_READ_UNCOMMITTED
Definition: xact.h:36
#define XACT_REPEATABLE_READ
Definition: xact.h:38
#define XACT_READ_COMMITTED
Definition: xact.h:37
@ WAL_COMPRESSION_NONE
Definition: xlog.h:82
@ WAL_COMPRESSION_LZ4
Definition: xlog.h:84
@ WAL_COMPRESSION_PGLZ
Definition: xlog.h:83
@ WAL_COMPRESSION_ZSTD
Definition: xlog.h:85
@ RECOVERY_PREFETCH_OFF
@ RECOVERY_PREFETCH_ON
@ RECOVERY_PREFETCH_TRY
@ XMLBINARY_BASE64
Definition: xml.h:35
@ XMLBINARY_HEX
Definition: xml.h:36