From a9a17f206e7847445ec03e6f87aeb794d8c5fa25 Mon Sep 17 00:00:00 2001 From: Ian Barwick Date: Wed, 15 Nov 2017 20:50:13 +0900 Subject: [PATCH] docs: improve documentation of pg_basebackup_options --- doc/appendix-faq.sgml | 15 ++++++++++++--- doc/cloning-standbys.sgml | 17 +++++++++++++++-- 2 files changed, 27 insertions(+), 5 deletions(-) diff --git a/doc/appendix-faq.sgml b/doc/appendix-faq.sgml index 480c8707..24c50c66 100644 --- a/doc/appendix-faq.sgml +++ b/doc/appendix-faq.sgml @@ -142,7 +142,7 @@ I've provided replication permission for the <literal>repmgr</literal> user in <filename>pg_hba.conf</filename> but <command>repmgr</command>/<application>repmgrd</application> complains it can't connect to the server... Why? - repmgr andrepmgrd need to be able to connect to the repmgr database + repmgr and repmgrd need to be able to connect to the repmgr database with a normal connection to query metadata. The replication connection permission is for PostgreSQL's streaming replication (and doesn't necessarily need to be the repmgr user). @@ -155,8 +155,17 @@ Cloning a standby is a one-time action; the role of the server being cloned from could change, so fixing it in the configuration file would create confusion. If &repmgr; needs to establish a connection to the primary - server, it can retrieve this from the repmgr.nodes table or if necessary - scan the replication cluster until it locates the active primary. + server, it can retrieve this from the repmgr.nodes table on the local + node, and if necessary scan the replication cluster until it locates the active primary. + + + + + When cloning a standby, how do I ensure the WAL files are placed in a custom directory? + + Provide the option --waldir (--xlogdir in PostgreSQL 9.6 + and earlier) with the absolute path to the WAL directory in pg_basebackup_options. + For more details see . diff --git a/doc/cloning-standbys.sgml b/doc/cloning-standbys.sgml index d3a589b7..68bfcbac 100644 --- a/doc/cloning-standbys.sgml +++ b/doc/cloning-standbys.sgml @@ -347,6 +347,11 @@ pg_basebackup options when cloning a standby + + As &repmgr; uses pg_basebackup to clone a standby, it's possible to + provide additional parameters for pg_basebackup to customise the + cloning process. + By default, pg_basebackup performs a checkpoint before beginning the backup process. However, a normal checkpoint may take some time to complete; @@ -362,8 +367,16 @@ - Further options can be passed to the pg_basebackup utility via - the setting pg_basebackup_options in repmgr.conf. + Other options can be passed to pg_basebackup by including them + in the repmgr.conf setting pg_basebackup_options. + + + If using a separate directory to store WAL files, provide the option --waldir + (--xlogdir in PostgreSQL 9.6 and earlier) with the absolute path to the + WAL directory. Any WALs generated during the cloning process will be copied here, and + a symlink will automatically be created from the main data directory. + + See the PostgreSQL pg_basebackup documentation for more details of available options.