disable trigger_file option from recovery.conf

Triggering of a slave to stop replication and enable writing works.
However if a second slave (with data persistence) is reconfigured to
use the first slave (triggered) as the master, the second slave cannot
replicate the data.

At the moment the only way to convert a slave to a master is to stop it
and start it as a master in which case the above issue is not seen.

To avoid users from trying to trigger a slave, we removed the config
altogether until the issue can be resolved.
This commit is contained in:
Sameer Naik
2015-11-30 11:57:44 +05:30
parent ba9d02ecb3
commit c1cce0328c
+1 -1
View File
@@ -261,7 +261,7 @@ configure_recovery() {
exec_as_postgres touch ${PG_RECOVERY_CONF}
( echo "standby_mode = 'on'";
echo "primary_conninfo = 'host=${REPLICATION_HOST} port=${REPLICATION_PORT} user=${REPLICATION_USER} password=${REPLICATION_PASS} sslmode=${REPLICATION_SSLMODE}'";
echo "trigger_file = '/tmp/postgresql.trigger'" ) > ${PG_RECOVERY_CONF}
) > ${PG_RECOVERY_CONF}
else
set_recovery_param "host" "${REPLICATION_HOST}"
set_recovery_param "port" "${REPLICATION_PORT}"