Re: PG 12 beta 1 segfault during analyze

From: Andres Freund <andres(at)anarazel(dot)de>
To: Steve Singer <steve(at)ssinger(dot)info>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, PostgreSQL-development Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: PG 12 beta 1 segfault during analyze
Date: 2019-06-18 23:02:40
Message-ID: 20190618230240.6i3m2jhqclztdyuz@alap3.anarazel.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi,

On 2019-06-17 21:46:02 -0400, Steve Singer wrote:
> On 6/15/19 10:18 PM, Tom Lane wrote:
> > Steve Singer <steve(at)ssinger(dot)info> writes:
> > > I encountered the following segfault when running against a PG 12 beta1
> > > during a analyze against a table.
> > Nobody else has reported this, so you're going to have to work on
> > producing a self-contained test case, or else debugging it yourself.
> >
> > regards, tom lane
> >
> >
> >
> The attached patch fixes the issue.

Thanks for the bug report, diagnosis and patch. Pushed.

I included a small testcase for ANALYZE running in a transaction that
also modified a few rows, after going back and forth on it for a
while. Seems unlikely that we'll reintroduce this specific bug, but it
seems good to have test coverage a least some of the
HEAPTUPLE_DELETE_IN_PROGRESS path. We currently have none...

I think the testcase would catch the issue at hand on most machines, by
mixing live/dead/deleted-by-current-transaction rows.

Greetings,

Andres Freund

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Andres Freund 2019-06-18 23:08:43 Re: openssl valgrind failures on skink are due to openssl issue
Previous Message Alvaro Herrera 2019-06-18 22:25:47 Re: pgsql: Avoid spurious deadlocks when upgrading a tuple lock