Re: Missed check for too-many-children in bgworker spawning
Stephen Frost <sfrost@snowman.net>
From: Stephen Frost <sfrost@snowman.net>
To: Andres Freund <andres@anarazel.de>
Cc: Robert Haas <robertmhaas@gmail.com>, Tom Lane <tgl@sss.pgh.pa.us>, PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Date: 2019-11-04T19:09:45Z
Lists: pgsql-hackers
Greetings, * Andres Freund (andres@anarazel.de) wrote: > On 2019-10-09 12:29:18 -0400, Robert Haas wrote: > > I would say rather that if fork() is failing on your system, you have > > a not very stable system. > > I don't think that's really true, fwiw. It's often a good idea to turn > on strict memory overcommit accounting, and with that set, it's actually > fairly common to see fork() fail with ENOMEM, even if there's > practically a reasonable amount of resources. Especially with larger > shared buffers and without huge pages, the amount of memory needed for a > postmaster child in the worst case is not insubstantial. I've not followed this thread very closely, but I agree with Andres here wrt fork() failing with ENOMEM in the field and not because the system isn't stable. Thanks, Stephen
Commits
-
Check for too many postmaster children before spawning a bgworker.
- 8c2910ce5ed7 9.5.20 landed
- c69e982a60fb 9.6.16 landed
- 7e8d0eb63fbb 12.1 landed
- 3887e9455f81 13.0 landed
- 1b5c2ddcdefc 10.11 landed
- 021065aac676 11.6 landed
-
Report an ERROR if a parallel worker fails to start properly.
- 2badb5afb89c 11.0 cited