Updates to README and --help output

This commit is contained in:
Ian Barwick
2016-12-26 11:45:58 +09:00
parent a6f1c6e483
commit 1bdc72a07b
2 changed files with 24 additions and 16 deletions

View File

@@ -243,14 +243,14 @@ command line options:
### Logging ### Logging
By default `repmgr` and `repmgrd` will log directly to `STDERR`. For `repmgrd` we By default `repmgr` and `repmgrd` will log directly to `STDERR`. For `repmgrd`
recommend capturing output in a logfile or using your system's log facility; we recommend capturing output in a logfile or using your system's log facility;
see `repmgr.conf.sample` for details. see `repmgr.conf.sample` for details.
As a command line utility, `repmgr` will normally log directly to the console - As a command line utility, `repmgr` will directly to the console by default
this is a change in behaviour from previous versions, where it would always (this is a change in behaviour from versions before 3.3, where it would always
log to the same location as `repmgrd`. However in some circumstances, e.g. when log to the same location as `repmgrd`). However in some circumstances, such as
`repmgr` is executed by `repmgrd` during a failover event, it makes sense to when `repmgr` is executed by `repmgrd` during a failover event, it makes sense to
capture `repmgr`'s log output - this can be done by supplying the command-line capture `repmgr`'s log output - this can be done by supplying the command-line
option `--log-to-file` to `repmgr`. option `--log-to-file` to `repmgr`.
@@ -289,14 +289,14 @@ Setting up a simple replication cluster with repmgr
The following section will describe how to set up a basic replication cluster The following section will describe how to set up a basic replication cluster
with a master and a standby server using the `repmgr` command line tool. with a master and a standby server using the `repmgr` command line tool.
It is assumed PostgreSQL is installed on both servers in the cluster, It is assumed PostgreSQL is installed on both servers in the cluster,
`rsync` is available and password-less SSH connections are possible between `rsync` is available and passwordless SSH connections are possible between
both servers. both servers.
* * * * * *
> *TIP*: for testing `repmgr`, it's possible to use multiple PostgreSQL > *TIP*: for testing `repmgr`, it's possible to use multiple PostgreSQL
> instances running on different ports on the same computer, with > instances running on different ports on the same computer, with
> password-less SSH access to `localhost` enabled. > passwordless SSH access to `localhost` enabled.
* * * * * *
@@ -736,13 +736,22 @@ string passed to `repmgr` with `-d/--dbname` (see above for details), and/or set
appropriate environment variables. appropriate environment variables.
Note that PostgreSQL will always set explicit defaults for `sslmode` and Note that PostgreSQL will always set explicit defaults for `sslmode` and
`sslcompression`. `sslcompression` (and from PostgreSQL 10.0 also `target_session_attrs`).
If `application_name` is set in the standby's `conninfo` parameter in If `application_name` is set in the standby's `conninfo` parameter in
`repmgr.conf`, this value will be appended to `primary_conninfo`, otherwise `repmgr.conf`, this value will be appended to `primary_conninfo`, otherwise
`repmgr` will set `application_name` to the same value as the `node_name` `repmgr` will set `application_name` to the same value as the `node_name`
parameter. parameter.
By default `repmgr` assumes the user who owns the `repmgr` metadatabase will
also be the replication user; a different replication user can be specified
with `--replication-user`.
If the upstream server requires a password, and this was provided via
`PGPASSWORD`, `.pgpass` etc., by default `repmgr` will include this in
`primary_conninfo`. Use the command line option `--no-conninfo-password` to
suppress this.
Setting up cascading replication with repmgr Setting up cascading replication with repmgr
-------------------------------------------- --------------------------------------------
@@ -1555,7 +1564,7 @@ which contains connection details for the local database.
bootstrapping new installations. To update an existing but 'stale' bootstrapping new installations. To update an existing but 'stale'
data directory (for example belonging to a failed master), `rsync` data directory (for example belonging to a failed master), `rsync`
must be used by specifying `--rsync-only`. In this case, must be used by specifying `--rsync-only`. In this case,
password-less SSH connections between servers are required. passwordless SSH connections between servers are required.
* `standby promote` * `standby promote`
@@ -1575,7 +1584,7 @@ which contains connection details for the local database.
Promotes a standby to master and demotes the existing master to a standby. Promotes a standby to master and demotes the existing master to a standby.
This command must be run on the standby to be promoted, and requires a This command must be run on the standby to be promoted, and requires a
password-less SSH connection to the current master. Additionally the passwordless SSH connection to the current master. Additionally the
location of the master's `repmgr.conf` file must be provided with location of the master's `repmgr.conf` file must be provided with
`-C/--remote-config-file`. `-C/--remote-config-file`.
@@ -1682,7 +1691,7 @@ which contains connection details for the local database.
overview of connections between all databases in the cluster. overview of connections between all databases in the cluster.
These commands require a valid `repmgr.conf` file on each node. These commands require a valid `repmgr.conf` file on each node.
Additionally password-less `ssh` connections are required between Additionally passwordless `ssh` connections are required between
all nodes. all nodes.
Example 1 (all nodes up): Example 1 (all nodes up):

View File

@@ -6569,7 +6569,7 @@ do_help(void)
printf(_(" --upstream-conninfo 'primary_conninfo' value to write in recovery.conf\n" \ printf(_(" --upstream-conninfo 'primary_conninfo' value to write in recovery.conf\n" \
" when the intended upstream server does not yet exist\n")); " when the intended upstream server does not yet exist\n"));
printf(_(" --recovery-min-apply-delay=VALUE set recovery_min_apply_delay in recovery.conf (PostgreSQL 9.4 and later)\n")); printf(_(" --recovery-min-apply-delay=VALUE set recovery_min_apply_delay in recovery.conf (PostgreSQL 9.4 and later)\n"));
printf(_(" --replication-user username to set in 'primary_conninfo' in recovery.conf\\n")); printf(_(" --replication-user username to set in 'primary_conninfo' in recovery.conf\n"));
printf(_(" --without-barman do not use Barman even if configured\n")); printf(_(" --without-barman do not use Barman even if configured\n"));
printf(_(" -w, --wal-keep-segments minimum value for the GUC wal_keep_segments (default: %s)\n"), DEFAULT_WAL_KEEP_SEGMENTS); printf(_(" -w, --wal-keep-segments minimum value for the GUC wal_keep_segments (default: %s)\n"), DEFAULT_WAL_KEEP_SEGMENTS);
@@ -6580,11 +6580,10 @@ do_help(void)
" standby (optional timeout in seconds)\n")); " standby (optional timeout in seconds)\n"));
printf(_(" --recovery-min-apply-delay=VALUE (standby follow) set recovery_min_apply_delay\n" \ printf(_(" --recovery-min-apply-delay=VALUE (standby follow) set recovery_min_apply_delay\n" \
" in recovery.conf (PostgreSQL 9.4 and later)\n")); " in recovery.conf (PostgreSQL 9.4 and later)\n"));
printf(_(" --replication-user (standby follow) username to set in 'primary_conninfo' in recovery.conf\\n")); printf(_(" --replication-user (standby follow) username to set in 'primary_conninfo' in recovery.conf\n"));
printf(_(" -W, --wait (standby follow) wait for a master to appear\n")); printf(_(" -W, --wait (standby follow) wait for a master to appear\n"));
printf(_(" -m, --mode (standby switchover) shutdown mode (\"fast\" - default, \"smart\" or \"immediate\")\n")); printf(_(" -m, --mode (standby switchover) shutdown mode (\"fast\" - default, \"smart\" or \"immediate\")\n"));
printf(_(" -C, --remote-config-file (standby switchover) path to the configuration file on\n" \ printf(_(" -C, --remote-config-file (standby switchover) path to the configuration file on the current master\n"));
" the current master\n"));
printf(_(" --pg_rewind[=VALUE] (standby switchover) 9.3/9.4 only - use pg_rewind if available,\n" \ printf(_(" --pg_rewind[=VALUE] (standby switchover) 9.3/9.4 only - use pg_rewind if available,\n" \
" optionally providing a path to the binary\n")); " optionally providing a path to the binary\n"));
printf(_(" -k, --keep-history=VALUE (cluster cleanup) retain indicated number of days of history (default: 0)\n")); printf(_(" -k, --keep-history=VALUE (cluster cleanup) retain indicated number of days of history (default: 0)\n"));