Re: BUG #17268: Possible corruption in toast index after reindex index concurrently

From: Alexey Ermakov <alexey(dot)ermakov(at)dataegret(dot)com>
To: Maxim Boguk <maxim(dot)boguk(at)gmail(dot)com>, Andres Freund <andres(at)anarazel(dot)de>
Cc: PostgreSQL mailing lists <pgsql-bugs(at)lists(dot)postgresql(dot)org>, Peter Geoghegan <pg(at)bowt(dot)ie>, Michael Paquier <michael(at)paquier(dot)xyz>
Subject: Re: BUG #17268: Possible corruption in toast index after reindex index concurrently
Date: 2021-11-08 11:04:40
Message-ID: 366f7247-709e-c07c-4875-068be1121c3a@dataegret.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Hello,

On 2021-11-08 02:29, Maxim Boguk wrote:
> On Sun, Nov 7, 2021 at 2:07 AM Andres Freund <andres(at)anarazel(dot)de> wrote:
>> Hi,
>>
>> On November 4, 2021 1:01:44 PM PDT, Maxim Boguk <maxim(dot)boguk(at)gmail(dot)com> wrote:
>>> UPDATE: the problem base table entry which had erroneous toast data
>>> definitely had been created during the REINDEX run of toast idx.
>> Do you have any details about the transaction / application that inserted the data?
> Well... jdbc with server side prepared statements off (pgbouncer).
>

I was told that application inserts rows into given table with queries like:

INSERT INTO zz (id, body) VALUES (?, ?) ON CONFLICT (id) DO NOTHING

inside transaction. It's possible to attempt to insert row with same id
several times inside one transaction (in that case usually that id is
new one i.e. was not presented in the table before that transaction).

Hope it could help in some way.

--

Thanks,

Alexey Ermakov

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Devrim Gündüz 2021-11-08 12:26:27 Re: BUG #17274: Issue in upgrading package pgrouting: not signed
Previous Message Semab Tariq 2021-11-08 09:09:15 Re: CREATE INDEX CONCURRENTLY does not index prepared xact's data