diff options
author | Heikki Linnakangas <heikki.linnakangas@iki.fi> | 2012-09-05 18:10:15 -0700 |
---|---|---|
committer | Heikki Linnakangas <heikki.linnakangas@iki.fi> | 2012-09-05 18:57:54 -0700 |
commit | 4b8dacfcef7ad16939ec8695019747fb45a80847 (patch) | |
tree | 6e6737bb93f7fca799e930515531f9b0fcd4e35d /src/bin/scripts/clusterdb.c | |
parent | 308d4ec4c677a2ced29b82dde811b1cbba8c3201 (diff) | |
download | postgresql-4b8dacfcef7ad16939ec8695019747fb45a80847.tar.gz postgresql-4b8dacfcef7ad16939ec8695019747fb45a80847.zip |
Fix WAL file replacement during cascading replication on Windows.
When the startup process restores a WAL file from the archive, it deletes
any old file with the same name and renames the new file in its place. On
Windows, however, when a file is deleted, it still lingers as long as a
process holds a file handle open on it. With cascading replication, a
walsender process can hold the old file open, so the rename() in the startup
process would fail. To fix that, rename the old file to a temporary name, to
make the original file name available for reuse, before deleting the old
file.
Diffstat (limited to 'src/bin/scripts/clusterdb.c')
0 files changed, 0 insertions, 0 deletions