postgresql/src/bin
Noah Misch d18f6674bd Initialize random() in bootstrap/stand-alone postgres and in initdb.
This removes a difference between the standard IsUnderPostmaster
execution environment and that of --boot and --single.  In a stand-alone
backend, "SELECT random()" always started at the same seed.

On a system capable of using posix shared memory, initdb could still
conclude "selecting dynamic shared memory implementation ... sysv".
Crashed --boot or --single postgres processes orphaned shared memory
objects having names that collided with the not-actually-random names
that initdb probed.  The sysv fallback appeared after ten crashes of
--boot or --single postgres.  Since --boot and --single are rare in
production use, systems used for PostgreSQL development are the
principal candidate to notice this symptom.

Back-patch to 9.3 (all supported versions).  PostgreSQL 9.4 introduced
dynamic shared memory, but 9.3 does share the "SELECT random()" problem.

Reviewed by Tom Lane and Kyotaro HORIGUCHI.

Discussion: https://postgr.es/m/20180915221546.GA3159382@rfd.leadboat.com
2018-09-23 22:56:39 -07:00
..
initdb Initialize random() in bootstrap/stand-alone postgres and in initdb. 2018-09-23 22:56:39 -07:00
pg_archivecleanup Don't fall off the end of perl functions 2018-05-27 09:08:42 -04:00
pg_basebackup Allow concurrent-safe open() and fopen() in frontend code for Windows 2018-09-14 10:04:14 +09:00
pg_config Translation updates 2018-05-21 12:29:52 -04:00
pg_controldata Translation updates 2018-06-25 12:37:18 +02:00
pg_ctl Implement "pg_ctl logrotate" command 2018-09-01 19:46:49 +03:00
pg_dump Remove dead code from pop_next_work_item(). 2018-09-17 12:43:07 -04:00
pg_resetwal Avoid using potentially-under-aligned page buffers. 2018-09-01 15:27:17 -04:00
pg_rewind Message style improvements 2018-09-13 23:35:43 +02:00
pg_test_fsync Translation updates 2018-05-21 12:29:52 -04:00
pg_test_timing Translation updates 2018-05-21 12:29:52 -04:00
pg_upgrade Avoid using potentially-under-aligned page buffers. 2018-09-01 15:27:17 -04:00
pg_verify_checksums Allow concurrent-safe open() and fopen() in frontend code for Windows 2018-09-14 10:04:14 +09:00
pg_waldump Avoid using potentially-under-aligned page buffers. 2018-09-01 15:27:17 -04:00
pgbench Fix pgbench lexer's "continuation" rule to cope with Windows newlines. 2018-09-17 12:11:43 -04:00
pgevent Update copyright for 2018 2018-01-02 23:30:12 -05:00
psql Get rid of explicit argument-count markings in tab-complete.c. 2018-09-21 20:50:41 -04:00
scripts Add semicolons to end of internally run queries 2018-08-30 19:23:22 +02:00
Makefile Allow on-line enabling and disabling of data checksums 2018-04-05 22:04:48 +02:00