From: | Daniel Wood <hexexpert(at)comcast(dot)net> |
---|---|
To: | Michael Paquier <michael(at)paquier(dot)xyz> |
Cc: | pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: 'Invalid lp' during heap_xlog_delete |
Date: | 2019-11-09 02:44:08 |
Message-ID: | 875232803.252469.1573267449176@connect.xfinity.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
I repro'ed on PG11 and PG10 STABLE but several months old.
I looked at 6d05086 but it doesn't address the core issue.
DropRelFileNodeBuffers prevents the checkpoint from writing all needed dirty pages for any REDO's that exist BEFORE the truncate. If we crash after a checkpoint but before the physical truncate then the REDO will need to replay the operation against the dirty page that the Drop invalidated.
Teja Mupparti, an engineer I work with, suggested moving DropRelFileNodeBuffers to the bottom of smgrtruncate() after the physical truncate. Doing that along with a fsync() after the truncate seems to plug the hole.
> On November 8, 2019 at 5:39 PM Michael Paquier < michael(at)paquier(dot)xyz mailto:michael(at)paquier(dot)xyz > wrote:
>
>
> On Fri, Nov 08, 2019 at 12:46:51PM -0800, Daniel Wood wrote:
>
> > > Is DropRelFileNodeBuffers purely for performance or would there be
> > any correctness problems if not done.
> >
> > > On which version did you find that? Only HEAD or did you use a
> version on a stable branch? There has been some work done in this
> area lately as of 6d05086.
> --
> Michael
>
From | Date | Subject | |
---|---|---|---|
Next Message | Amit Kapila | 2019-11-09 03:23:40 | Re: Frequent HLL bitstream_unpack crashes |
Previous Message | Michael Paquier | 2019-11-09 02:26:10 | Re: pg_upgrade fails with non-standard ACL |