Skip to content

Commit 797b0fc

Browse files
committed
doc: Move remove_temp_files_after_crash to section for developer options
The main goal of this option is to allow inspecting temporary files for debugging purposes, so moving the parameter there is natural. Oversight in cd91de0. Reported-by: Justin Pryzby Author: Euler Taveira Discussion: https://postgr.es/m/20210612004347.GP16435@telsasoft.com
1 parent 9b4e4cf commit 797b0fc

File tree

3 files changed

+22
-26
lines changed

3 files changed

+22
-26
lines changed

doc/src/sgml/config.sgml

Lines changed: 19 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -9863,28 +9863,6 @@ dynamic_library_path = 'C:\tools\postgresql;H:\my_project\lib;$libdir'
98639863
</listitem>
98649864
</varlistentry>
98659865

9866-
<varlistentry id="guc-remove-temp-files-after-crash" xreflabel="remove_temp_files_after_crash">
9867-
<term><varname>remove_temp_files_after_crash</varname> (<type>boolean</type>)
9868-
<indexterm>
9869-
<primary><varname>remove_temp_files_after_crash</varname> configuration parameter</primary>
9870-
</indexterm>
9871-
</term>
9872-
<listitem>
9873-
<para>
9874-
When set to <literal>on</literal>, which is the default,
9875-
<productname>PostgreSQL</productname> will automatically remove
9876-
temporary files after a backend crash. If disabled, the files will be
9877-
retained and may be used for debugging, for example. Repeated crashes
9878-
may however result in accumulation of useless files.
9879-
</para>
9880-
9881-
<para>
9882-
This parameter can only be set in the <filename>postgresql.conf</filename>
9883-
file or on the server command line.
9884-
</para>
9885-
</listitem>
9886-
</varlistentry>
9887-
98889866
<varlistentry id="guc-data-sync-retry" xreflabel="data_sync_retry">
98899867
<term><varname>data_sync_retry</varname> (<type>boolean</type>)
98909868
<indexterm>
@@ -10912,6 +10890,25 @@ LOG: CleanUpLock: deleting: lock(0xb7acd844) id(24688,24696,0,0,0,1)
1091210890
</listitem>
1091310891
</varlistentry>
1091410892

10893+
<varlistentry id="guc-remove-temp-files-after-crash" xreflabel="remove_temp_files_after_crash">
10894+
<term><varname>remove_temp_files_after_crash</varname> (<type>boolean</type>)
10895+
<indexterm>
10896+
<primary><varname>remove_temp_files_after_crash</varname> configuration parameter</primary>
10897+
</indexterm>
10898+
</term>
10899+
<listitem>
10900+
<para>
10901+
When set to <literal>on</literal>, which is the default,
10902+
<productname>PostgreSQL</productname> will automatically remove
10903+
temporary files after a backend crash. If disabled, the files will be
10904+
retained and may be used for debugging, for example. Repeated crashes
10905+
may however result in accumulation of useless files. This parameter
10906+
can only be set in the <filename>postgresql.conf</filename> file or on
10907+
the server command line.
10908+
</para>
10909+
</listitem>
10910+
</varlistentry>
10911+
1091510912
</variablelist>
1091610913
</sect1>
1091710914
<sect1 id="runtime-config-short">

src/backend/utils/misc/guc.c

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1404,9 +1404,10 @@ static struct config_bool ConfigureNamesBool[] =
14041404
NULL, NULL, NULL
14051405
},
14061406
{
1407-
{"remove_temp_files_after_crash", PGC_SIGHUP, ERROR_HANDLING_OPTIONS,
1407+
{"remove_temp_files_after_crash", PGC_SIGHUP, DEVELOPER_OPTIONS,
14081408
gettext_noop("Remove temporary files after backend crash."),
1409-
NULL
1409+
NULL,
1410+
GUC_NOT_IN_SAMPLE
14101411
},
14111412
&remove_temp_files_after_crash,
14121413
true,

src/backend/utils/misc/postgresql.conf.sample

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -768,8 +768,6 @@
768768

769769
#exit_on_error = off # terminate session on any error?
770770
#restart_after_crash = on # reinitialize after backend crash?
771-
#remove_temp_files_after_crash = on # remove temporary files after
772-
# backend crash?
773771
#data_sync_retry = off # retry or panic on failure to fsync
774772
# data?
775773
# (change requires restart)

0 commit comments

Comments
 (0)