Hot Standby
PostgreSQL has shipped with an integrated standby feature since its 8.2 version. This allows creating a master/standby pair of nodes, where the standby regularly receives a log of database updates from the master. With the currently common warm standby configuration, introduced in PostgreSQL 8.2, this allows a high availability setup where, if the master is lost, the slave can be brought up quickly to replace it.
Starting with PostgreSQL 9.0, it's possible to run queries against the standby server or servers as well. This Hot Standby feature lets you scale up read workload by using a pool of multiple read-only servers. You just need to architect your application so that all writes go to the master node.
Terminology
There are several terms that you need to know in order to follow any discussion of warm or Hot Standby setups:
- Write-ahead log (WAL): PostgreSQL writes information to a series of WAL files, in segments of 16 MB in size, before making corresponding changes to the database...