postgresql/src/bin
Michael Paquier 4fca146009 Fix error handling of vacuumdb when running out of fds
When trying to use a high number of jobs, vacuumdb has only checked for
a maximum number of jobs used, causing confusing failures when running
out of file descriptors when the jobs open connections to Postgres.
This commit changes the error handling so as we do not check anymore for
a maximum number of allowed jobs when parsing the option value with
FD_SETSIZE, but check instead if a file descriptor is within the
supported range when opening the connections for the jobs so as this is
detected at the earliest time possible.

Also, improve the error message to give a hint about the number of jobs
recommended, using a wording given by the reviewers of the patch.

Reported-by: Andres Freund
Author: Michael Paquier
Reviewed-by: Andres Freund, Álvaro Herrera, Tom Lane
Discussion: https://postgr.es/m/20190818001858.ho3ev4z57fqhs7a5@alap3.anarazel.de
Backpatch-through: 9.5
2019-08-26 11:14:33 +09:00
..
initdb Translation updates 2019-08-05 15:44:33 +02:00
pg_archivecleanup Translation updates 2018-08-06 20:03:55 +02:00
pg_basebackup Don't uselessly escape a string that doesn't need escaping 2019-07-26 17:46:40 -04:00
pg_config Translation updates 2019-05-06 14:43:35 +02:00
pg_controldata Translation updates 2019-05-06 14:43:35 +02:00
pg_ctl Honor TEMP_CONFIG in TAP suites. 2019-05-11 00:23:02 -07:00
pg_dump Un-break pg_dump for pre-8.3 source servers. 2019-08-13 16:57:58 -04:00
pg_resetwal Translation updates 2019-05-06 14:43:35 +02:00
pg_rewind Translation updates 2019-08-05 15:44:33 +02:00
pg_test_fsync Translation updates 2019-05-06 14:43:35 +02:00
pg_test_timing Translation updates 2018-08-06 20:03:55 +02:00
pg_upgrade Translation updates 2019-08-05 15:44:33 +02:00
pg_waldump Translation updates 2019-02-11 14:25:01 +01:00
pgbench Fix compiler warning 2019-08-12 21:20:14 +02:00
pgevent Phase 3 of pgindent updates. 2017-06-21 15:35:54 -04:00
psql Avoid platform-specific null pointer dereference in psql. 2019-08-25 15:04:04 -04:00
scripts Fix error handling of vacuumdb when running out of fds 2019-08-26 11:14:33 +09:00
Makefile Rename user-facing tools with "xlog" in the name to say "wal". 2017-02-09 16:23:46 -05:00