pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Fujii Masao <masao.fujii@oss.nttdata.com>
To: Kyotaro Horiguchi <horikyota.ntt@gmail.com>
Cc: sk@zsrv.org
Cc: a.lubennikova@postgrespro.ru
Cc: robertmhaas@gmail.com
Cc: michael@paquier.xyz
Cc: andres@anarazel.de
Cc: peter.eisentraut@2ndquadrant.com
Cc: pgsql-hackers@postgresql.org
Subject: Re: Allow some recovery parameters to be changed with reload
Date: Wed, 2 Dec 2020 11:01:52 +0900
Message-ID: <aab54031-ae9d-3199-2d01-7fb739b69f38@oss.nttdata.com> (raw)
In-Reply-To: <20201127.120545.1039699675559027058.horikyota.ntt@gmail.com>
References: <d33c954e-a505-66bc-996e-5a92caaffbfe@oss.nttdata.com>
	<20201127.093040.1121089236433501638.horikyota.ntt@gmail.com>
	<44876a44-60a9-c45e-15a2-5fe3239f0a09@oss.nttdata.com>
	<20201127.120545.1039699675559027058.horikyota.ntt@gmail.com>



On 2020/11/27 12:05, Kyotaro Horiguchi wrote:
> At Fri, 27 Nov 2020 09:48:25 +0900, Fujii Masao <masao.fujii@oss.nttdata.com> wrote in
>>
>>
>> On 2020/11/27 9:30, Kyotaro Horiguchi wrote:
>>> At Thu, 26 Nov 2020 22:43:48 +0900, Fujii Masao
>>> <masao.fujii@oss.nttdata.com> wrote in
>>>>
>>>>
>>>> On 2020/11/12 4:38, Sergei Kornilov wrote:
>>>>> Hello
>>>>>
>>>>>> Anyway, for now I think that your first patch would be enough, i.e.,
>>>>>> just change the context of restore_command to PGC_SIGHUP.
>>>>> Glad to hear. Attached a rebased version of the original proposal.
>>>>
>>>> Thanks for rebasing the patch!
>>>>
>>>>       This parameter is required for archive recovery,
>>>>
>>>> I found the above description in config.sgml. I was just wondering
>>>> if it should be updated so that the actual specification is described
>>>> or not.
>>>> The actual spec is that restore_command is required to start archive
>>>> recovery, but optional (i.e., the parameter can be reset to an empty)
>>>> after archive recovery has started. But this updated version of
>>>> description would be rather confusing to users. So I'm now thinking
>>>> not to update that.
>>>>
>>>> Does anyone object to the patch? If no, I'm thinking to commit the
>>>> patch.
>>> Although I don't object to make the parameter reloadable, I think it
>>> needs to be documented that server could stop after reloading if the
>>> server failed to execute the new command line.
>>
>> You mean that we should document that if restore_command is set to
>> improper command mistakenly, archive recovery may fail to restore some
>> archived WAL files and finish without replaying those WAL? But isn't
>> this true even without applying the patch?
> 
> If we set a wrong command in .conf and start the server in recovery
> mode, the server immediately stops. It's fine.  If we change
> restore_command wrong way on a running server, "pg_ctl reload" stops
> the server.  If it is a hot standby, the server stops unexpectedly.
> 
> However, after rechecking, I found that recovery_end_command with
> wrong content causes server stop at the end of recovery, or at
> promotion. And that variable is PGC_SIGHUP.
> 
> So I agree not to document that.  Sorry for the noise.

OK, so I pushed the patch. Thanks!

Regards,

-- 
Fujii Masao
Advanced Computing Technology Center
Research and Development Headquarters
NTT DATA CORPORATION





view thread (30+ messages)  latest in thread

Message-ID: <aab54031-ae9d-3199-2d01-7fb739b69f38@oss.nttdata.com>
Permalink:  ../aab54031-ae9d-3199-2d01-7fb739b69f38@oss.nttdata.com/
Also on:    postgresql.org/message-id/aab54031-ae9d-3199-2d01-7fb739b69f38@oss.nttdata.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-hackers@postgresql.org
  Cc: masao.fujii@oss.nttdata.com, horikyota.ntt@gmail.com, sk@zsrv.org, a.lubennikova@postgrespro.ru, robertmhaas@gmail.com, michael@paquier.xyz, andres@anarazel.de, peter.eisentraut@2ndquadrant.com
  Subject: Re: Allow some recovery parameters to be changed with reload
  In-Reply-To: <aab54031-ae9d-3199-2d01-7fb739b69f38@oss.nttdata.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox