]> granicus.if.org Git - postgresql/commit
Get rid of the dynamic shared memory state file.
authorRobert Haas <rhaas@postgresql.org>
Tue, 8 Apr 2014 15:39:55 +0000 (11:39 -0400)
committerRobert Haas <rhaas@postgresql.org>
Tue, 8 Apr 2014 15:39:55 +0000 (11:39 -0400)
commit11a65eed1637a05b03e174700799b024e104bfb4
treec6634e65fcfc2f3eb7e86f09d18ac9562a46cb24
parent0886fc6a5c75b294544263ea979b9cf6195407d9
Get rid of the dynamic shared memory state file.

Instead of storing the ID of the dynamic shared memory control
segment in a file within the data directory, store it in the main
control segment.  This avoids a number of nasty corner cases,
most seriously that doing an online backup and then using it on
the same machine (e.g. to fire up a standby) would result in the
standby clobbering all of the master's dynamic shared memory
segments.

Per complaints from Heikki Linnakangas, Fujii Masao, and Tom
Lane.
src/backend/port/sysv_shmem.c
src/backend/port/win32_shmem.c
src/backend/storage/ipc/dsm.c
src/backend/storage/ipc/ipci.c
src/include/storage/dsm.h
src/include/storage/pg_shmem.h