diff --git a/doc/repmgr-witness-register.sgml b/doc/repmgr-witness-register.sgml
index 84bde114..d6d7a676 100644
--- a/doc/repmgr-witness-register.sgml
+++ b/doc/repmgr-witness-register.sgml
@@ -23,14 +23,19 @@
use of the witness server with repmgrd.
- When executing repmgr witness register, connection information
- for the cluster primary server must also be provided. &repmgr; will automatically
- use the user and dbname values defined
- in the conninfo string defined in the witness node's
- repmgr.conf, if these are not explicitly provided.
+ When executing repmgr witness register, database connection
+ information for the cluster primary server must also be provided.
- Execute with the --dry-run option to check what would happen
+ In most cases it's only necessary to provide the primary's hostname with
+ the / option; &repmgr; will
+ automatically use the user and dbname
+ values defined in the conninfo string defined in the
+ witness node's repmgr.conf, unless these are explicitly
+ provided as command line options.
+
+
+ Execute with the option to check what would happen
without actually registering the witness server.
diff --git a/repmgr-action-witness.c b/repmgr-action-witness.c
index 16597e55..e487d2e7 100644
--- a/repmgr-action-witness.c
+++ b/repmgr-action-witness.c
@@ -484,13 +484,15 @@ void do_witness_help(void)
printf(_("Usage:\n"));
printf(_(" %s [OPTIONS] witness register\n"), progname());
printf(_(" %s [OPTIONS] witness unregister\n"), progname());
-
+ puts("");
printf(_("WITNESS REGISTER\n"));
puts("");
printf(_(" \"witness register\" registers a witness node.\n"));
puts("");
- printf(_(" Requires provision of connection information for the primary\n"));
+ printf(_(" Requires provision of connection information for the primary node,\n"));
+ printf(_(" typically usually just the hostname.\n"));
puts("");
+ printf(_(" -h/--hostname hostname of the primary node\n"));
printf(_(" --dry-run check prerequisites but don't make any changes\n"));
printf(_(" -F, --force overwrite an existing node record\n"));
puts("");
diff --git a/repmgr-client.c b/repmgr-client.c
index b1766cad..de1ed911 100644
--- a/repmgr-client.c
+++ b/repmgr-client.c
@@ -1399,7 +1399,7 @@ check_cli_parameters(const int action)
if (!runtime_options.host_param_provided)
{
item_list_append_format(&cli_errors,
- _("host name for the source node must be provided when executing %s"),
+ _("host name for the source node must be provided with -h/--hostname when executing %s"),
action_name(action));
}
@@ -1456,7 +1456,7 @@ check_cli_parameters(const int action)
if (!runtime_options.host_param_provided)
{
item_list_append_format(&cli_errors,
- _("host name for the source node must be provided when executing %s"),
+ _("host name for the source node must be provided with -h/--hostname when executing %s"),
action_name(action));
}
}