Re: "ERROR: could not open relation with OID 16391" error was encountered when reindexing

From: feichanghong <feichanghong(at)qq(dot)com>
To: Michael Paquier <michael(at)paquier(dot)xyz>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Aleksander Alekseev <aleksander(at)timescale(dot)com>, pgsql-hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: "ERROR: could not open relation with OID 16391" error was encountered when reindexing
Date: 2024-01-17 07:56:14
Message-ID: tencent_0970A420002AA9BDFB648077027C309B840A@qq.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

>
> For this specific job, I have always wanted a try_index_open() that
> would attempt to open the index with a relkind check, perhaps we could
> introduce one and reuse it here?

Yes, replacing index_open with try_index_open solves the problem. The
idea is similar to my initial report of "after successfully opening the heap
table in reindex_index, check again whether the index still exists”.
But it should be better to introduce try_index_open.


Best Regards,
Fei Changhong
Alibaba Cloud Computing Ltd.

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message feichanghong 2024-01-17 08:03:46 Re: "ERROR: could not open relation with OID 16391" error was encountered when reindexing
Previous Message Kyotaro Horiguchi 2024-01-17 07:48:59 Re: POC PATCH: copy from ... exceptions to: (was Re: VLDB Features)