From 705b52fde4e8fa8813e8d10db0bdbe52cf9dba86 Mon Sep 17 00:00:00 2001 From: Ian Barwick Date: Thu, 31 Aug 2017 11:00:48 +0900 Subject: [PATCH] Use actual program name rather than "repmgr" when executing remote commands It's possible some distribution packages may assign a different name to the "repmgr" binary (typically appending a version number), so we shouldn't hard-code into the command string. However it's reasonable to assume the "repmgr" binary will have the same name across a replication cluster so we won't engage in any contortions to account for possible variations. See: https://github.com/2ndQuadrant/repmgr/issues/323 --- repmgr-client.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/repmgr-client.c b/repmgr-client.c index 67c31934..af7096c9 100644 --- a/repmgr-client.c +++ b/repmgr-client.c @@ -2796,7 +2796,7 @@ make_remote_repmgr_path(PQExpBufferData *output_buf, t_node_info *remote_node_re { appendPQExpBuffer(output_buf, "%s -f %s ", - make_pg_path("repmgr"), + make_pg_path(progname()), remote_node_record->config_file); }