33.4. Fault Tolerance and High Availability #
Postgres Pro Shardman provides out-of-the-box fault tolerance. The shardmand daemon monitors the cluster configuration and manages BiHA clusters, which are used to guarantee high availability of all shards and fault tolerance. The common Postgres Pro Shardman configuration (shardmand, BiHA clusters) is stored in an etcd cluster.
In the case of automatic failover, BiHA will take care of automatically changing slave to master and failed master to standby. Information about the current states of PostgreSQL instances is periodically stored in etcd and used by cluster software.
If necessary, you can switch to a new primary manually by running the shardmanctl shard switch
command.
You can specify some high-availability options to define cluster behavior in a fault state: masterDemotionEnabled, masterDemotionTimeout, minSyncMonitorEnabled and minSyncMonitorUnhealthyTimeout.