]> granicus.if.org Git - postgresql/commit
Arrange to fsync the contents of lockfiles (both postmaster.pid and the
authorTom Lane <tgl@sss.pgh.pa.us>
Mon, 16 Aug 2010 17:33:22 +0000 (17:33 +0000)
committerTom Lane <tgl@sss.pgh.pa.us>
Mon, 16 Aug 2010 17:33:22 +0000 (17:33 +0000)
commite8b4a23b12f99fb15f2aabd1d6b649d5bdf9fb83
treef7f10831f54e924249a423e257f4c3ec365f6f5c
parent4d1dd8d86567b61b42131d8e271ce587f645ac8b
Arrange to fsync the contents of lockfiles (both postmaster.pid and the
socket lockfile) when writing them.  The lack of an fsync here may well
explain two different reports we've seen of corrupted lockfile contents,
which doesn't particularly bother the running server but can prevent a
new server from starting if the old one crashes.  Per suggestion from
Alvaro.

Back-patch to all supported versions.
src/backend/utils/init/miscinit.c