Book Image

PostgreSQL Replication, Second Edition

Book Image

PostgreSQL Replication, Second Edition

Overview of this book

Table of Contents (22 chapters)
PostgreSQL Replication Second Edition
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Index

Synchronous replication setup


As mentioned before, synchronous replication has been made to protect your data at all costs. The core idea of synchronous replication is that a transaction must be on at least two servers before the master returns success to the client. Making sure that data is on at least two nodes is a key requirement to ensure no data loss in the event of a crash.

Setting up synchronous replication works just like setting up asynchronous replication. Just a handful of parameters discussed in this chapter have to be changed to enjoy the blessings of synchronous replication. However, if you are about to create a setup based on synchronous replication, we recommend getting started with an asynchronous setup and gradually extending your configuration and turning it into synchronous replication. This will allow you to debug things more easily and avoid problems down the road.

Understanding the downside to synchronous replication

The most important thing you have to know about synchronous...