pg.ddx.io pgsql-bugs@postgresql.org mailing list archivehelp / color / mirror / Atom feed
From: Michael Paquier <michael@paquier.xyz>
To: Jehan-Guillaume de Rorthais <jgdr@dalibo.com>
Cc: Kyotaro Horiguchi <horikyota.ntt@gmail.com>
Cc: masao.fujii@oss.nttdata.com
Cc: pgsql-bugs@lists.postgresql.org
Subject: Re: [BUG] non archived WAL removed during production crash recovery
Date: Thu, 23 Apr 2020 08:46:18 +0900
Message-ID: <20200422234618.GI33034@paquier.xyz> (raw)
In-Reply-To: <20200422181717.491fb499@firost>
References: <20200418092611.GD350229@paquier.xyz>
<20200420.160231.719176619682386260.horikyota.ntt@gmail.com>
<20200420073444.GA77439@paquier.xyz>
<20200420142235.1536a73b@firost>
<20200421021501.GE77439@paquier.xyz>
<20200422004121.516a5a32@firost>
<20200422011935.GF33034@paquier.xyz>
<20200422073223.GG33034@paquier.xyz>
<20200422175824.637bda91@firost>
<20200422181717.491fb499@firost>
On Wed, Apr 22, 2020 at 06:17:17PM +0200, Jehan-Guillaume de Rorthais wrote:
> I found an extra useless line of code in v9 patch. Please, find in
> attachment v10. Sorry for this.
Thanks for helping here, your changes make sense. This looks mostly
fine to me except that part:
+$standby1->poll_query_until('postgres',
+ qq{ SELECT pg_xlog_location_diff('$primary_lsn', pg_last_xlog_replay_location()) = 0 })
+ or die "Timed out while waiting for xlog replay";
Here we should check if $primary_lsn is at least
pg_last_xlog_replay_location(). Checking for an equality may stuck
the test if more WAL gets replayed. For example you could have a
concurrent autovacuum generating WAL.
--
Michael
Attachments:
[application/pgp-signature] signature.asc (832B, ../20200422234618.GI33034@paquier.xyz/2-signature.asc)
download
view thread (67+ messages) latest in thread
Message-ID: <20200422234618.GI33034@paquier.xyz> Permalink: ../20200422234618.GI33034@paquier.xyz/ Also on: postgresql.org/message-id/20200422234618.GI33034@paquier.xyz ·
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-bugs@postgresql.org Cc: michael@paquier.xyz, jgdr@dalibo.com, horikyota.ntt@gmail.com, masao.fujii@oss.nttdata.com, pgsql-bugs@lists.postgresql.org Subject: Re: [BUG] non archived WAL removed during production crash recovery In-Reply-To: <20200422234618.GI33034@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