repmgr 3.3.2 released
What is repmgr?
repmgr is an open source package which greatly simplifies the process of setting up and managing replication using streaming replication within a cluster of PostgreSQL servers. Taking advantage of features introduced since PostgreSQL 9.3, repmgr builds on PostgreSQL's core functionality to provide a smooth, user-friendly way of working with the complexities of replication and failover management in high-availability environments.
repmgr consists of two core tools - the repmgr command line interface, which provides functionality for adminstering replication such as cloning standby servers, and repmgrd, a background daemon which monitors nodes in a replication cluster and provides automatic failover support.
Note that repmgr 3.3.2 supports PostgreSQL 9.3 and later only.
2ndQuadrant provides professional support services for repmgr - see our website for details.
Improvements in repmgr 3.3.2
Support for PostgreSQL 10
repmgr 3.3.2 has been updated to support the recently released PostgreSQL 10 beta 1, which contains a number of changes related to WAL functionality. Note that PostgreSQL 10 is still under development and should not be used in production, however we encourage users to test this version of repmgr with PostgreSQL 10 and report any issues.
New log line type DETAIL
Additional context for log messages is now provided in a seperate DETAIL log line (similar to PostgreSQL itself); this can be suppressed with the -t/--terse option.
Bugfixes in repmgr 3.3.2
ensure --replication-user option is honoured in all cases
When executing repmgr standby clone with --replication-user and passing database connection parameters as a conninfo string, the username provided with --replication-user was discarded.
Improve detection of pg_rewind on remote server
When executing repmgr standby switchover without pg_bindir being set, under some circumstances repmgr was unable to locate pg_rewind on the remote server.
Avoid spurious cluster name errors during repmgr standby switchover operations
repmgr was sometimes emitting error messages about not being able to determine a cluster name; this had no effect on the operation but was causing confusion.
Fix repl_status when executed on a standby
Column communication_time_lag was displaying an incorrect value.
Interpret missing -P option
Command line option -P/--pwprompt for a password prompt during witness server was ignoring -P
Upgrading from older repmgr versions
Upgrading from repmgr 3.1.2 or later
repmgr 3.3.2 can simply be installed in place of any version from repmgr 3.1.2 onwards.
If repmgrd is running, stop and restart the service to ensure it is running with the current repmgr version.
Upgrading from repmgr 3.1.1 or 3.1
To upgrade from repmgr 3.1.1 or repmgr 3.1 version, install repmgr 3.3.2 from your operating system's packaging system or from source, then perform following tasks:
- Run the provided repmgr database upgrade script, repmgr3.1.1_repmgr3.1.2.sql. This makes a small modification to the repl_nodes table's foreign key definition.
- If repmgrd is running, stop and restart the service to ensure it is running with the current repmgr version.
Upgrading from repmgr 3.0.x
repmgr 3.3.2 is a drop-in replacement for an existing repmgr 3.0.x installation. It should be installed first, either from your operating system's packaging system or from source, then following tasks performed:
- Run the provided repmgr database upgrade script, sql/repmgr3.0_repmgr3.1.sql. This introduces one new convenience view, repl_show_nodes, but otherwise no changes have been made to repmgr's metadata schema.
- Run the provided repmgr database upgrade script, sql/repmgr3.1.1_repmgr3.1.2.sql. This makes a small modification to the repl_nodes table's foreign key definition.
- If repmgrd is running, stop and restart the service to ensure it is running with the current repmgr version.
Upgrading from repmgr 2.0
repmgr 3.3.2 can replace an existing repmgr 2.0 installation. It should be installed first, either from your operating system's packaging system or from source, then following tasks performed:
- If repmgrd is running, stop the service.
-
Run the provided repmgr database upgrade script, sql/repmgr2_repmgr3.sql,
which is required to expand the
repl_nodes
table. - Run the provided repmgr database upgrade script, sql/repmgr3.0_repmgr3.1.sql. This introduces one new convenience view, repl_show_nodes.
- Run the provided repmgr database upgrade script, sql/repmgr3.1.1_repmgr3.1.2.sql. This makes a small modification to the repl_nodes table's foreign key definition.
- Restart repmgrd if previously stopped.
Community and development
repmgr is free and open source software and is licensed under the GPLv3.
Contributions to repmgr are welcome. See CONTRIBUTING.md for information about how to contribute.