Re: Reproducible GIST index corruption under concurrent updates
Duncan Sands <duncan.sands@deepbluecap.com>
From: Duncan Sands <duncan.sands@deepbluecap.com>
To: Heikki Linnakangas <hlinnaka@iki.fi>,
Andrey Borodin <x4mmm@yandex-team.ru>
Cc: pgsql-bugs@lists.postgresql.org
Date: 2021-01-20T08:23:14Z
Lists: pgsql-bugs
> The comment change was correct, but the condition used &&. Should've been ||. > There is another copy of basically the same condition earlier in the function > that was changed correctly, but I blundered this one. Oops. > > The attached patch fixes this. I also added an assertion to the > gistplacetopage() function, to check that we never try to insert on a deleted > page. This bug could've made that happen too, although in this case the problem > was a concurrent split, not a deletion. I'll backpatch and push this tomorrow. > > Many thanks for the easy reproducer script, Duncan! No problem Heikki, thanks for the quick fix. Best wishes, Duncan.
Commits
Same data as JSON:
GET /api/v1/messages/:b64id/commits
the thread's linked commits as JSON, with link sources.
API reference →
-
Fix bug in detecting concurrent page splits in GiST insert
- 0326635dd484 12.6 landed
- b8403d140f4e 13.2 landed
- 6b4d3046f422 14.0 landed
-
Refactor checks for deleted GiST pages.
- e2e992c93145 12.0 cited