Re: Improve handling of parameter differences in physical replication - Mailing list pgsql-hackers

From Michael Paquier
Subject Re: Improve handling of parameter differences in physical replication
Date
Msg-id 20200228074547.GE2688@paquier.xyz
Whole thread Raw
In response to Re: Improve handling of parameter differences in physical replication  (Peter Eisentraut <peter.eisentraut@2ndquadrant.com>)
Responses Re: Improve handling of parameter differences in physical replication  (Peter Eisentraut <peter.eisentraut@2ndquadrant.com>)
List pgsql-hackers
On Thu, Feb 27, 2020 at 02:37:24PM +0100, Peter Eisentraut wrote:
> On 2020-02-27 11:13, Fujii Masao wrote:
>>> Btw., I think the current setup is slightly buggy.  The
> MaxBackends value that is used to size shared memory is computed as
> MaxConnections + autovacuum_max_workers + 1 + max_worker_processes +
> max_wal_senders, but we don't track autovacuum_max_workers in WAL.
>> Maybe this is because autovacuum doesn't work during recovery?
>
> Autovacuum on the primary can use locks or xids, and so it's possible that
> the standby when processing WAL encounters more of those than it has locally
> allocated shared memory to handle.

Putting aside your patch because that sounds like a separate issue..
Doesn't this mean that autovacuum_max_workers should be added to the
control file, that we need to record in WAL any updates done to it and
that CheckRequiredParameterValues() is wrong?
--
Michael

Attachment

pgsql-hackers by date:

Previous
From: Michael Paquier
Date:
Subject: Re: Make mesage at end-of-recovery less scary.
Next
From: Peter Eisentraut
Date:
Subject: Re: Improve handling of parameter differences in physical replication