Re: v12.0: segfault in reindex CONCURRENTLY

From: Michael Paquier <michael(at)paquier(dot)xyz>
To: Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>
Cc: Justin Pryzby <pryzby(at)telsasoft(dot)com>, pgsql-hackers(at)lists(dot)postgresql(dot)org, Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com>, Andreas Karlsson <andreas(at)proxel(dot)se>
Subject: Re: v12.0: segfault in reindex CONCURRENTLY
Date: 2019-10-15 06:35:47
Message-ID: 20191015063547.GA2602@paquier.xyz
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Mon, Oct 14, 2019 at 08:57:16AM +0900, Michael Paquier wrote:
> I need to think about that, but shouldn't we have a way to reproduce
> that case rather reliably with an isolation test? The patch looks to
> good to me, these are also the two places I spotted yesterday after a
> quick lookup. The only other caller is isTempNamespaceInUse() which
> does its thing correctly.

Actually, reindex-concurrently.spec stresses that, except that in
order to reproduce the failure we need to close the connection exactly
in the waiting loop before sending the progress report but after
looking at VirtualTransactionIdIsValid. Using a debugger and a simple
checkpoint I can easily reproduce the crash, but we'd need more to
make that test case deterministic, like a termination with the correct
timing.

So, Alvaro, your patch looks good to me. Could you apply it?
--
Michael

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Amit Kapila 2019-10-15 06:37:52 Questions/Observations related to Gist vacuum
Previous Message Masahiko Sawada 2019-10-15 05:08:20 Re: Transparent Data Encryption (TDE) and encrypted files