From: Nathan Bossart <nathan@postgresql.org>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Introduce num_os_semaphores GUC.
Date: Fri, 26 Jul 2024 20:29:13 +0000
Message-ID: <E1sXRYv-001M2q-Gp@gemulon.postgresql.org> (raw)
Introduce num_os_semaphores GUC.
The documentation for System V IPC parameters provides complicated
formulas to determine the appropriate values for SEMMNI and SEMMNS.
Furthermore, these formulas have often been wrong because folks
forget to update them (e.g., when adding a new auxiliary process).
This commit introduces a new runtime-computed GUC named
num_os_semaphores that reports the number of semaphores needed for
the configured number of allowed connections, worker processes,
etc. This new GUC allows us to simplify the formulas in the
documentation, and it should help prevent future inaccuracies.
Like the other runtime-computed GUCs, users can view it with
"postgres -C" before starting the server, which is useful for
preconfiguring the necessary operating system resources.
Reviewed-by: Tom Lane, Sami Imseih, Andres Freund, Robert Haas
Discussion: https://postgr.es/m/20240517164452.GA1914161%40nathanxps13
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/0dcaea56903489e8abedf231f286272495c3beb4
Modified Files
--------------
doc/src/sgml/config.sgml | 18 ++++++++++++++++++
doc/src/sgml/runtime.sgml | 31 +++++++++++++++++++------------
src/backend/storage/ipc/ipci.c | 6 +++++-
src/backend/utils/misc/guc_tables.c | 12 ++++++++++++
4 files changed, 54 insertions(+), 13 deletions(-)
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-committers@postgresql.org
Cc: nathan@postgresql.org, pgsql-committers@lists.postgresql.org
Subject: Re: pgsql: Introduce num_os_semaphores GUC.
In-Reply-To: <E1sXRYv-001M2q-Gp@gemulon.postgresql.org>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox