mirror of
https://github.com/postgres/postgres.git
synced 2025-07-27 12:41:57 +03:00
Create a GUC parameter max_files_per_process that is a configurable
upper limit on what we will believe from sysconf(_SC_OPEN_MAX). The default value is 1000, so that under ordinary conditions it won't affect the behavior. But on platforms where the kernel promises far more than it can deliver, this can be used to prevent running out of file descriptors. See numerous past discussions, eg, pgsql-hackers around 23-Dec-2000.
This commit is contained in:
@ -1,5 +1,5 @@
|
||||
<!--
|
||||
$Header: /cvsroot/pgsql/doc/src/sgml/runtime.sgml,v 1.85 2001/09/23 21:52:36 petere Exp $
|
||||
$Header: /cvsroot/pgsql/doc/src/sgml/runtime.sgml,v 1.86 2001/09/30 18:57:45 tgl Exp $
|
||||
-->
|
||||
|
||||
<Chapter Id="runtime">
|
||||
@ -1218,6 +1218,26 @@ dynamic_library_path = '/usr/local/lib/postgresql:/home/my_project/lib:$libdir'
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><varname>MAX_FILES_PER_PROCESS</varname> (<type>integer</type>)</term>
|
||||
<listitem>
|
||||
<para>
|
||||
Sets the maximum number of simultaneously open files in each server
|
||||
process. The default is 1000. The limit actually used by the code
|
||||
is the smaller of this setting and the result of
|
||||
<literal>sysconf(_SC_OPEN_MAX)</literal>.
|
||||
Therefore, on systems where sysconf returns a reasonable limit,
|
||||
you don't need to worry about this setting. But on some platforms
|
||||
(notably, most BSD systems), sysconf returns a value that is much
|
||||
larger than the system can really support when a large number of
|
||||
processes all try to open that many files. If you find yourself
|
||||
seeing <quote>Too many open files</> failures, try reducing this
|
||||
setting.
|
||||
This option can only be set at server start.
|
||||
</para>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><varname>MAX_FSM_RELATIONS</varname> (<type>integer</type>)</term>
|
||||
<listitem>
|
||||
|
Reference in New Issue
Block a user