]> granicus.if.org Git - postgresql/commit
Don't allow walsender to send WAL data until it's been safely fsync'd on the
authorTom Lane <tgl@sss.pgh.pa.us>
Thu, 17 Jun 2010 16:41:25 +0000 (16:41 +0000)
committerTom Lane <tgl@sss.pgh.pa.us>
Thu, 17 Jun 2010 16:41:25 +0000 (16:41 +0000)
commit07e8b6aabcca3ad9a67681694d955f607e29ce7b
tree0d7aff9b127566412a2bd3b8606ae501b3c11f91
parent8f4e1218458d0d34825d41b50aabadacbdf93697
Don't allow walsender to send WAL data until it's been safely fsync'd on the
master.  Otherwise a subsequent crash could cause the master to lose WAL that
has already been applied on the slave, resulting in the slave being out of
sync and soon corrupt.  Per recent discussion and an example from Robert Haas.

Fujii Masao
src/backend/access/transam/xlog.c
src/backend/replication/walsender.c
src/include/access/xlog.h