On 1/29/15 11:34 AM, Bruce Momjian wrote: > 3. Check that the replica is not very lagged. If it is, wait for > traffic to die down and for it to catch up.
I think I'd want a something a bit more specific here. When the primary shuts down it will kick out one last WAL. The filename should be recorded. > 7. shut down postgres on the replica. Before the shutdown make sure that the replicas are waiting on the subsequent log file to appear (note that versions prior to 9.3 skip 00). That means all WAL has been consumed and the primary and replica(s) are in the same state. This is a bit more complex if streaming replication is being used *without* good old fashioned log shipping to a backup server and I'm not sure exactly how to go about it. I suppose you could start Postgres in single user mode, commit a transaction, and make sure that transaction gets to the replicas. OTOH, streaming replication (unless it is synchronous) would be crazy without doing WAL backup. Maybe that's just me. -- - David Steele da...@pgmasters.net
signature.asc
Description: OpenPGP digital signature