From: Michael Paquier <michael@paquier.xyz>
To: Arseny Sher <a.sher@postgrespro.ru>
Cc: PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Subject: Re: Flaky vacuum truncate test in reloptions.sql
Date: Tue, 30 Mar 2021 16:12:19 +0900
Message-ID: <YGLOWsO2bV7KLvh7@paquier.xyz> (raw)
In-Reply-To: <87tuotr2hh.fsf@ars-thinkpad>
References: <87tuotr2hh.fsf@ars-thinkpad>
On Tue, Mar 30, 2021 at 01:58:50AM +0300, Arseny Sher wrote:
> Intimate reading of lazy_scan_heap says that the failure indeed might
> happen; if ConditionalLockBufferForCleanup couldn't lock the buffer and
> either the buffer doesn't need freezing or vacuum is not aggressive, we
> don't insist on close inspection of the page contents and count it as
> nonempty according to lazy_check_needs_freeze. It means the page is
> regarded as such even if it contains only garbage (but occupied) ItemIds,
> which is the case of the test. And of course this allegedly nonempty
> page prevents the truncation. Obvious competitors for the page are
> bgwriter/checkpointer; the chances of a simultaneous attack are small
> but they exist.
Yep, this is the same problem as the one discussed for c2dc1a7, where
a concurrent checkpoint may cause a page to be skipped, breaking the
test.
> I'm a bit puzzled that I've ever seen this only when running regression
> tests under our multimaster. While multimaster contains a fair amount of
> C code, I don't see how any of it can interfere with the vacuuming
> business here. I can't say I did my best to create the repoduction
> though -- the explanation above seems to be enough.
Why not just using DISABLE_PAGE_SKIPPING instead here?
--
Michael
Attachments:
[application/pgp-signature] signature.asc (832B, ../YGLOWsO2bV7KLvh7@paquier.xyz/2-signature.asc)
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.sher@postgrespro.ru, pgsql-hackers@lists.postgresql.org
Subject: Re: Flaky vacuum truncate test in reloptions.sql
In-Reply-To: <YGLOWsO2bV7KLvh7@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