From: Michael Paquier <michael@paquier.xyz>
To: Anastasia Lubennikova <a.lubennikova@postgrespro.ru>
Cc: Michael Banck <michael.banck@credativ.de>
Cc: PostgreSQL Development <pgsql-hackers@postgresql.org>
Subject: Re: [patch] Fix checksum verification in base backups for zero page headers
Date: Wed, 28 Oct 2020 16:43:44 +0900
Message-ID: <20201028074344.GL28445@paquier.xyz> (raw)
In-Reply-To: <20201028071156.GK28445@paquier.xyz>
References: <20201007081852.GC30037@paquier.xyz>
<608f3476-0598-2514-2c03-e05c7d2b0cbd@postgrespro.ru>
<20201020062432.GA30362@paquier.xyz>
<69b38451-e91f-95fc-c3ce-06eb778d36e0@postgrespro.ru>
<20201022012519.GF1475@paquier.xyz>
<036235b4-2461-c4b2-a448-7875d943ce1e@postgrespro.ru>
<20201022230008.GK1475@paquier.xyz>
<20201026011315.GA2973@paquier.xyz>
<ce25a60e-bd70-6554-1e8f-7e4dc9f6ce59@postgrespro.ru>
<20201028071156.GK28445@paquier.xyz>
On Wed, Oct 28, 2020 at 04:11:56PM +0900, Michael Paquier wrote:
> Thanks. The patch for v13 cannot use a macro, but one of the versions
> of upthread would do just fine. I have been wondering about using the
> new CheckBuffer() for the purpose of the retry to make it
> concurrent-safe, but by looking at the code I think that we would run
> unto problems when trying to open through smgr.c any relation file in
> global/ as these require an invalid backend ID, and a WAL sender does
> not satisfy that (see the assertion in GetRelationPath()).
Actually, scratch that.. It looks like I am wrong here. By using
smgropen() with InvalidBackendId and a RelFileNode built using the
path of the file being sent, similarly to what pg_rewind is doing in
isRelDataFile(), we should have everything that's needed. This is
too complicated for a backpatch and we should have some consolidation
with pg_rewind, so using the sleep/retry for v13 sounds like a safer
path to take in the stable branch.
--
Michael
Attachments:
signature.asc (application/pgp-signature, 832B) download
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: michael@paquier.xyz, a.lubennikova@postgrespro.ru, michael.banck@credativ.de
Subject: Re: [patch] Fix checksum verification in base backups for zero page headers
In-Reply-To: <20201028074344.GL28445@paquier.xyz>
* 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