From cedc5e20fbb7278b42af14c18f8fc98350cac18c Mon Sep 17 00:00:00 2001 From: Jaime Casanova Date: Tue, 26 Jul 2011 16:12:51 -0500 Subject: [PATCH] Add a check to ensure 'hot_standby=on' on master. While this parameter doesn't have an effect here it will be a reminder for users, besides will reduce things user have to do on the standby --- repmgr.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/repmgr.c b/repmgr.c index d4a7cda7..df86aca5 100644 --- a/repmgr.c +++ b/repmgr.c @@ -715,6 +715,12 @@ do_standby_clone(void) log_err(_("%s needs parameter 'archive_mode' to be set to 'on'\n"), progname); exit(ERR_BAD_CONFIG); } + if (!guc_setted(conn, "hot_standby", "=", "on")) + { + PQfinish(conn); + log_err(_("%s needs parameter 'hot_standby' to be set to 'on'\n"), progname); + exit(ERR_BAD_CONFIG); + } /* * Check if the tablespace locations exists and that we can write to