mirror of
https://github.com/postgres/postgres.git
synced 2025-07-02 09:02:37 +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:
@ -4,7 +4,7 @@
|
||||
* Support for grand unified configuration scheme, including SET
|
||||
* command, configuration file, and command line options.
|
||||
*
|
||||
* $Header: /cvsroot/pgsql/src/backend/utils/misc/guc.c,v 1.53 2001/09/29 04:02:25 tgl Exp $
|
||||
* $Header: /cvsroot/pgsql/src/backend/utils/misc/guc.c,v 1.54 2001/09/30 18:57:45 tgl Exp $
|
||||
*
|
||||
* Copyright 2000 by PostgreSQL Global Development Group
|
||||
* Written by Peter Eisentraut <peter_e@gmx.net>.
|
||||
@ -31,6 +31,7 @@
|
||||
#include "optimizer/paths.h"
|
||||
#include "optimizer/planmain.h"
|
||||
#include "parser/parse_expr.h"
|
||||
#include "storage/fd.h"
|
||||
#include "storage/freespace.h"
|
||||
#include "storage/lock.h"
|
||||
#include "storage/proc.h"
|
||||
@ -302,6 +303,9 @@ static struct config_int
|
||||
{"vacuum_mem", PGC_USERSET, &VacuumMem,
|
||||
8192, 1024, INT_MAX, NULL, NULL},
|
||||
|
||||
{"max_files_per_process", PGC_BACKEND, &max_files_per_process,
|
||||
1000, 25, INT_MAX, NULL, NULL},
|
||||
|
||||
{"debug_level", PGC_USERSET, &DebugLvl,
|
||||
0, 0, 16, NULL, NULL},
|
||||
|
||||
|
Reference in New Issue
Block a user