Re: pgsql: Integrate recovery.conf into postgresql.conf

From: Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com>
To: Sergei Kornilov <sk(at)zsrv(dot)org>, Michael Paquier <michael(at)paquier(dot)xyz>
Cc: Postgres hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: pgsql: Integrate recovery.conf into postgresql.conf
Date: 2018-11-26 13:06:36
Message-ID: cd804d8f-0873-f81c-2420-2f1b0f99d889@2ndquadrant.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers pgsql-hackers

On 26/11/2018 13:32, Sergei Kornilov wrote:
>> Timed out while waiting for standby to catch up at
>> t/003_recovery_targets.pl line 34.
>
> I can reproduce this and notice wrong assign settings order. For example standby_6 has
>> recovery_target_name = '$recovery_name'
>> recovery_target_xid = '$recovery_txid'
>> recovery_target_time = '$recovery_time'
> But recoveryTarget was set to RECOVERY_TARGET_XID
> Without -DEXEC_BACKEND all fine.
>
> As far as I understand the guc.c code with EXEC_BACKEND all processes uses different config processing logic. We serialize all GUC and restore at process start. And we sort GUC by name in build_guc_variables - so we restore settings in wrong order. I was afraid that the GUC system does not guarantee the order of settings...
>
> What is preferable solution? Seems we can not simple change this logic.

What is the reason for allowing multiple recovery_target_* settings and
taking the last one? Could we change this aspect to make this behave
better?

> I think i can reorganize all new recovery_target_* GUC into single one with format, for example, recovery_target = "xid:607" (was mentioned in patch discussion).

That would be another option.

--
Peter Eisentraut http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

In response to

Responses

Browse pgsql-committers by date

  From Date Subject
Next Message Michael Paquier 2018-11-26 13:16:40 Re: pgsql: Integrate recovery.conf into postgresql.conf
Previous Message Sergei Kornilov 2018-11-26 12:32:10 Re: pgsql: Integrate recovery.conf into postgresql.conf

Browse pgsql-hackers by date

  From Date Subject
Next Message Michael Paquier 2018-11-26 13:16:40 Re: pgsql: Integrate recovery.conf into postgresql.conf
Previous Message Surafel Temesgen 2018-11-26 13:05:15 Re: COPY FROM WHEN condition