git.postgresql.org Git - postgresql.git/commit
2009年6月25日 21:36:00 +0000 (21:36 +0000)
2009年6月25日 21:36:00 +0000 (21:36 +0000)
commit 7e48b77b1cebb9a43f9fdd6b17128a0ba36132f9
Fix some serious bugs in archive recovery, now that bgwriter is active
during it:
When bgwriter is active, the startup process can't perform mdsync() correctly
because it won't see the fsync requests accumulated in bgwriter's private
pendingOpsTable. Therefore make bgwriter responsible for the end-of-recovery
checkpoint as well, when it's active.
When bgwriter is active (= archive recovery), the startup process must not
accumulate fsync requests to its own pendingOpsTable, since bgwriter won't
see them there when it performs restartpoints. Make startup process drop its
pendingOpsTable when bgwriter is launched to avoid that.
Update minimum recovery point one last time when leaving archive recovery.
It won't be updated by the end-of-recovery checkpoint because XLogFlush()
sees us as out of recovery already.
This fixes bug #4879 reported by Fujii Masao.
This is the main PostgreSQL git repository.
RSS
Atom