summaryrefslogtreecommitdiff
path: root/doc/src
diff options
context:
space:
mode:
authorStephen Frost <sfrost@snowman.net>2015-05-08 19:09:26 -0400
committerStephen Frost <sfrost@snowman.net>2015-05-08 19:09:26 -0400
commita97e0c3354ace5d74c6873cd5e98444757590be8 (patch)
tree769046f2783f3725a47466b893e9fd1d07bd9466 /doc/src
parentbab64ef9e8bc56fa5db9bd41cefb54c3d8051dbe (diff)
Add pg_file_settings view and function
The function and view added here provide a way to look at all settings in postgresql.conf, any #include'd files, and postgresql.auto.conf (which is what backs the ALTER SYSTEM command). The information returned includes the configuration file name, line number in that file, sequence number indicating when the parameter is loaded (useful to see if it is later masked by another definition of the same parameter), parameter name, and what it is set to at that point. This information is updated on reload of the server. This is unfiltered, privileged, information and therefore access is restricted to superusers through the GRANT system. Author: Sawada Masahiko, various improvements by me. Reviewers: David Steele
Diffstat (limited to 'doc/src')
-rw-r--r--doc/src/sgml/catalogs.sgml78
1 files changed, 78 insertions, 0 deletions
diff --git a/doc/src/sgml/catalogs.sgml b/doc/src/sgml/catalogs.sgml
index 4b79958b357..2756652be21 100644
--- a/doc/src/sgml/catalogs.sgml
+++ b/doc/src/sgml/catalogs.sgml
@@ -7560,6 +7560,11 @@
</row>
<row>
+ <entry><link linkend="view-pg-file-settings"><structname>pg_file_settings</structname></link></entry>
+ <entry>file location of parameter settings</entry>
+ </row>
+
+ <row>
<entry><link linkend="view-pg-shadow"><structname>pg_shadow</structname></link></entry>
<entry>database users</entry>
</row>
@@ -9173,6 +9178,79 @@ SELECT * FROM pg_locks pl LEFT JOIN pg_prepared_xacts ppx
</sect1>
+ <sect1 id="view-pg-file-settings">
+ <title><structname>pg_file_settings</structname></title>
+
+ <indexterm zone="view-pg-file-settings">
+ <primary>pg_file_settings</primary>
+ </indexterm>
+
+ <para>
+ The view <structname>pg_file_settings</structname> provides the file
+ name, line number and value of all parameters which are set through
+ configuration files.
+ In contrast to <structname>pg_settings</structname>, a row is provided for
+ each occurrence of the parameter across all configuration files. This is helpful
+ for discovering why one value may have been used in preference to another
+ when the parameters were loaded.
+ </para>
+
+ <table>
+ <title><structname>pg_file_settings</> Columns</title>
+
+ <tgroup cols="3">
+ <thead>
+ <row>
+ <entry>Name</entry>
+ <entry>Type</entry>
+ <entry>Description</entry>
+ </row>
+ </thead>
+ <tbody>
+ <row>
+ <entry><structfield>sourcefile</structfield></entry>
+ <entry><structfield>text</structfield></entry>
+ <entry>Path to and name of the configration file</entry>
+ </row>
+ <row>
+ <entry><structfield>sourceline</structfield></entry>
+ <entry><structfield>integer</structfield></entry>
+ <entry>
+ Line number within the configuration file where the value was set
+ </entry>
+ </row>
+ <row>
+ <entry><structfield>seqno</structfield></entry>
+ <entry><structfield>integer</structfield></entry>
+ <entry>Order in which the setting was loaded</entry>
+ </row>
+ <row>
+ <entry><structfield>name</structfield></entry>
+ <entry><structfield>text</structfield></entry>
+ <entry>Run-time configuration parameter name</entry>
+ </row>
+ <row>
+ <entry><structfield>setting</structfield></entry>
+ <entry><structfield>text</structfield></entry>
+ <entry>value of the parameter</entry>
+ </row>
+ </tbody>
+ </tgroup>
+ </table>
+
+ <para>
+ See <xref linkend="config-setting"> for more information about the various
+ ways to change these parameters.
+ </para>
+
+ <para>
+ The <structname>pg_file_settings</structname> view cannot be modified
+ directly as it represents information, as read in at server start or
+ reload time, about all parameter settings across all configuration files.
+ </para>
+
+</sect1>
+
<sect1 id="view-pg-shadow">
<title><structname>pg_shadow</structname></title>