summaryrefslogtreecommitdiff
path: root/doc/src
diff options
context:
space:
mode:
authorTom Lane2006-10-07 19:25:29 +0000
committerTom Lane2006-10-07 19:25:29 +0000
commit71a6f8b85b9f748dc7f33c1212c4474e8beb901a (patch)
treed3ae369b5edb5b1c199f4cae9d1a637432c75b15 /doc/src
parent1c160291ef61f46800616cb88d5a3a02156de4e3 (diff)
On platforms that have getrlimit(RLIMIT_STACK), use it to ensure that
max_stack_depth is not set to an unsafe value. This commit also provides configure-time checking for <sys/resource.h>, and cleans up some perhaps-unportable code associated with use of that include file and getrlimit().
Diffstat (limited to 'doc/src')
-rw-r--r--doc/src/sgml/config.sgml42
1 files changed, 25 insertions, 17 deletions
diff --git a/doc/src/sgml/config.sgml b/doc/src/sgml/config.sgml
index b3223e3de43..549ca755d70 100644
--- a/doc/src/sgml/config.sgml
+++ b/doc/src/sgml/config.sgml
@@ -1,4 +1,4 @@
-<!-- $PostgreSQL: pgsql/doc/src/sgml/config.sgml,v 1.89 2006/09/25 22:12:24 tgl Exp $ -->
+<!-- $PostgreSQL: pgsql/doc/src/sgml/config.sgml,v 1.90 2006/10/07 19:25:28 tgl Exp $ -->
<chapter Id="runtime-config">
<title>Server Configuration</title>
@@ -846,14 +846,22 @@ SET ENABLE_SEQSCAN TO OFF;
equivalent), less a safety margin of a megabyte or so. The safety
margin is needed because the stack depth is not checked in every
routine in the server, but only in key potentially-recursive routines
- such as expression evaluation. Setting the parameter higher than
- the actual kernel limit will mean that a runaway recursive function
- can crash an individual backend process. The default setting is
+ such as expression evaluation. The default setting is
2048 KB (two megabytes), which is conservatively small and unlikely
to risk crashes. However, it may be too small to allow execution
of complex functions.
Only superusers can change this setting.
</para>
+
+ <para>
+ Setting <varname>max_stack_depth</> higher than
+ the actual kernel limit will mean that a runaway recursive function
+ can crash an individual backend process. On platforms where
+ <productname>PostgreSQL</productname> can determine the kernel limit,
+ it will not let you set this variable to an unsafe value. However,
+ not all platforms provide the information, so caution is recommended
+ in selecting a value.
+ </para>
</listitem>
</varlistentry>
@@ -2173,19 +2181,6 @@ SELECT * FROM parent WHERE key = 2400;
</listitem>
</varlistentry>
- <varlistentry id="guc-gin-fuzzy-search-limit" xreflabel="gin_fuzzy_search_limit">
- <term><varname>gin_fuzzy_search_limit</varname> (<type>integer</type>)</term>
- <indexterm>
- <primary><varname>gin_fuzzy_search_limit</> configuration parameter</primary>
- </indexterm>
- <listitem>
- <para>
- Soft upper limit of the size of the set returned by GIN index. For more
- information see <xref linkend="gin-tips">.
- </para>
- </listitem>
- </varlistentry>
-
</variablelist>
</sect2>
</sect1>
@@ -3718,6 +3713,19 @@ dynamic_library_path = 'C:\tools\postgresql;H:\my_project\lib;$libdir'
</para>
</listitem>
</varlistentry>
+
+ <varlistentry id="guc-gin-fuzzy-search-limit" xreflabel="gin_fuzzy_search_limit">
+ <term><varname>gin_fuzzy_search_limit</varname> (<type>integer</type>)</term>
+ <indexterm>
+ <primary><varname>gin_fuzzy_search_limit</> configuration parameter</primary>
+ </indexterm>
+ <listitem>
+ <para>
+ Soft upper limit of the size of the set returned by GIN index. For more
+ information see <xref linkend="gin-tips">.
+ </para>
+ </listitem>
+ </varlistentry>
<varlistentry id="guc-local-preload-libraries" xreflabel="local_preload_libraries">
<term><varname>local_preload_libraries</varname> (<type>string</type>)</term>