mirror of
https://github.com/EnterpriseDB/repmgr.git
synced 2026-03-26 16:46:28 +00:00
Set synchronous_commit to off for current session
Forward-ported from 2.x; need to verify it makes sense.
This commit is contained in:
11
repmgr.c
11
repmgr.c
@@ -1114,6 +1114,17 @@ do_standby_clone(void)
|
||||
|
||||
if(runtime_options.rsync_only)
|
||||
{
|
||||
|
||||
/*
|
||||
* From pg 9.1 default is to wait for a sync standby to ack, avoid that by
|
||||
* turning off sync rep for this session
|
||||
*/
|
||||
if(set_config_bool(primary_conn, "synchronous_commit", false) == false)
|
||||
{
|
||||
PQfinish(primary_conn);
|
||||
exit(ERR_BAD_CONFIG);
|
||||
}
|
||||
|
||||
if(start_backup(primary_conn, first_wal_segment) == false)
|
||||
{
|
||||
r = ERR_BAD_BASEBACKUP;
|
||||
|
||||
Reference in New Issue
Block a user