Re: "ERROR: could not open relation with OID 16391" error was encountered when reindexing
Michael Paquier <michael@paquier.xyz>
From: Michael Paquier <michael@paquier.xyz>
To: feichanghong <feichanghong@qq.com>
Cc: Tom Lane <tgl@sss.pgh.pa.us>, Aleksander Alekseev <aleksander@timescale.com>, pgsql-hackers <pgsql-hackers@lists.postgresql.org>
Date: 2024-01-17T06:44:30Z
Lists: pgsql-hackers
Commits
Same data as JSON:
GET /api/v1/messages/:b64id/commits
the thread's linked commits as JSON, with link sources.
API reference →
-
Improve handling of dropped partitioned indexes for REINDEX INDEX
- b6f2e019d66f 14.11 landed
- a0c19de11566 15.6 landed
- c030e263e7fe 16.2 landed
- 0ae3b4662103 17.0 landed
-
Add try_index_open(), conditional variant of index_open()
- b685b41cf0a3 14.11 landed
- 1cf2dba84b18 15.6 landed
- 7ce65c6f7209 16.2 landed
- 8013850c853d 17.0 landed
On Wed, Jan 17, 2024 at 12:54:26AM +0800, feichanghong wrote: >> This is extremely nonspecific, as line numbers in our code change >> constantly. Please quote a chunk of code surrounding that >> and indicate which line you are trying to stop at. > > Thanks for the suggestion, I've refined the steps below to reproduce: Yeah, thanks for the steps. I am not surprised that there are still a few holes in this area. CONCURRENTLY can behave differently depending on the step where the old index is getting opened. 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? -- Michael