mirror of
https://github.com/EnterpriseDB/repmgr.git
synced 2026-03-22 22:56:29 +00:00
Rename t_configuration_options member 'pgctl_options' to 'pg_ctl_options'
Change is to make it match the actual configuration item.
This commit is contained in:
10
config.c
10
config.c
@@ -124,7 +124,7 @@ parse_config(const char *config_file, t_configuration_options *options)
|
||||
memset(options->rsync_options, 0, sizeof(options->rsync_options));
|
||||
memset(options->ssh_options, 0, sizeof(options->ssh_options));
|
||||
memset(options->pg_bindir, 0, sizeof(options->pg_bindir));
|
||||
memset(options->pgctl_options, 0, sizeof(options->pgctl_options));
|
||||
memset(options->pg_ctl_options, 0, sizeof(options->pg_ctl_options));
|
||||
memset(options->pg_basebackup_options, 0, sizeof(options->pg_basebackup_options));
|
||||
|
||||
/* default master_response_timeout is 60 seconds */
|
||||
@@ -210,7 +210,7 @@ parse_config(const char *config_file, t_configuration_options *options)
|
||||
else if (strcmp(name, "pg_bindir") == 0)
|
||||
strncpy(options->pg_bindir, value, MAXLEN);
|
||||
else if (strcmp(name, "pg_ctl_options") == 0)
|
||||
strncpy(options->pgctl_options, value, MAXLEN);
|
||||
strncpy(options->pg_ctl_options, value, MAXLEN);
|
||||
else if (strcmp(name, "pg_basebackup_options") == 0)
|
||||
strncpy(options->pg_basebackup_options, value, MAXLEN);
|
||||
else if (strcmp(name, "logfile") == 0)
|
||||
@@ -540,10 +540,10 @@ reload_config(char *config_file, t_configuration_options * orig_options)
|
||||
config_changed = true;
|
||||
}
|
||||
|
||||
/* pgctl_options */
|
||||
if(strcmp(orig_options->pgctl_options, new_options.pgctl_options) != 0)
|
||||
/* pg_ctl_options */
|
||||
if(strcmp(orig_options->pg_ctl_options, new_options.pg_ctl_options) != 0)
|
||||
{
|
||||
strcpy(orig_options->pgctl_options, new_options.pgctl_options);
|
||||
strcpy(orig_options->pg_ctl_options, new_options.pg_ctl_options);
|
||||
config_changed = true;
|
||||
}
|
||||
|
||||
|
||||
2
config.h
2
config.h
@@ -69,7 +69,7 @@ typedef struct
|
||||
int reconnect_attempts;
|
||||
int reconnect_intvl;
|
||||
char pg_bindir[MAXLEN];
|
||||
char pgctl_options[MAXLEN];
|
||||
char pg_ctl_options[MAXLEN];
|
||||
char pg_basebackup_options[MAXLEN];
|
||||
char logfile[MAXLEN];
|
||||
int monitor_interval_secs;
|
||||
|
||||
8
repmgr.c
8
repmgr.c
@@ -1768,7 +1768,7 @@ do_standby_follow(void)
|
||||
|
||||
/* Finally, restart the service */
|
||||
maxlen_snprintf(script, "%s %s -w -D %s -m fast restart",
|
||||
make_pg_path("pg_ctl"), options.pgctl_options, data_dir);
|
||||
make_pg_path("pg_ctl"), options.pg_ctl_options, data_dir);
|
||||
|
||||
log_notice(_("restarting server using '%s'\n"),
|
||||
script);
|
||||
@@ -1897,7 +1897,7 @@ do_witness_create(void)
|
||||
|
||||
sprintf(script, "%s %s -D %s init -o \"%s-U %s\"",
|
||||
make_pg_path("pg_ctl"),
|
||||
options.pgctl_options, runtime_options.dest_dir,
|
||||
options.pg_ctl_options, runtime_options.dest_dir,
|
||||
runtime_options.initdb_no_pwprompt ? "" : "-W ",
|
||||
runtime_options.superuser);
|
||||
log_info(_("initializing cluster for witness: %s.\n"), script);
|
||||
@@ -1968,7 +1968,7 @@ do_witness_create(void)
|
||||
/* start new instance */
|
||||
sprintf(script, "%s %s -w -D %s start",
|
||||
make_pg_path("pg_ctl"),
|
||||
options.pgctl_options, runtime_options.dest_dir);
|
||||
options.pg_ctl_options, runtime_options.dest_dir);
|
||||
log_info(_("starting witness server: %s\n"), script);
|
||||
r = system(script);
|
||||
if (r != 0)
|
||||
@@ -2079,7 +2079,7 @@ do_witness_create(void)
|
||||
/* reload to adapt for changed pg_hba.conf */
|
||||
sprintf(script, "%s %s -w -D %s reload",
|
||||
make_pg_path("pg_ctl"),
|
||||
options.pgctl_options, runtime_options.dest_dir);
|
||||
options.pg_ctl_options, runtime_options.dest_dir);
|
||||
log_info(_("reloading witness server configuration: %s"), script);
|
||||
r = system(script);
|
||||
if (r != 0)
|
||||
|
||||
Reference in New Issue
Block a user