In the last two posts (here and here) we’ve installed and configured DBVISIT StandbyMP for PostgreSQL and created a simple primary -> replica setup. Most of the replication setup was GUI driven and almost nothing had to be done manually, except for the creation of a user and configuration of pg_hba.conf. Currently we have the primary replicating to the replica and the StandbyMP management console managing this configuration:

One advantage of such a setup is, that the replica can take over the role of the primary and vice versa, e.g. when patching is required on one of the nodes. In StandbyMP this is called a “Graceful Switchover”, so lets try to do this and see what happens:

This takes a few second and the instances will have switched the roles:

The same works of course in the other direction.

If you prefer a graphical user interface for setting up and operating a primary -> replica configuration, then this could be an option for you. It is really easy to setup and you don’t have to touch the command line.