Re: data_checksums + debug_discard_caches = crash

From: Daniel Gustafsson <daniel(at)yesql(dot)se>
To: Fujii Masao <masao(dot)fujii(at)gmail(dot)com>
Cc: cca5507 <cca5507(at)qq(dot)com>, Mihail Nikalayeu <mihailnikalayeu(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: data_checksums + debug_discard_caches = crash
Date: 2026-08-04 10:02:43
Message-ID: D92E964E-14BB-403A-B4B0-6049C33AC747@yesql.se
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

> On 4 Aug 2026, at 05:47, Fujii Masao <masao(dot)fujii(at)gmail(dot)com> wrote:
>
> On Tue, Aug 4, 2026 at 12:22 PM cca5507 <cca5507(at)qq(dot)com> wrote:
>>
>>> While working on some stress suite I found the issue related to way
>>> ProcessSingleRelationByOid access rel->rd_smgr.
>>>
>>> Patch with fix and test is attached (it is self-explanatory and pretty simple).
>>
>> Good catch! I verify that the bug exists and your patch fixes it. Patch LGTM!
>
> +1
>
> The code change looks good to me.

Agreed, thanks for the report and patch!

> Is the new test really necessary? It only covers this specific data-checksums
> worker path, while debug_discard_caches can make the test time longer.

While useful for verifying the issue, I don't think we need to add this test
due to the increased test timing and the fairly low probability of it catching
anything now that the code is fixed.

Will push and backpatch to 19.

--
Daniel Gustafsson

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Andrey Borodin 2026-08-04 10:03:13 Re: [PATCH] Fix vacuum_delay_point happening inside lock
Previous Message Tomas Vondra 2026-08-04 10:01:40 Re: WAL compression setting after PostgreSQL LZ4 default change