Re: "ERROR: could not open relation with OID 16391" error was encountered when reindexing
feichanghong <feichanghong@qq.com>
From: feichanghong <feichanghong@qq.com>
To: feichanghong <feichanghong@qq.com>, Aleksander Alekseev <aleksander@timescale.com>
Cc: pgsql-hackers <pgsql-hackers@lists.postgresql.org>
Date: 2024-01-16T16:21:11Z
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
Attachments
- reproduce.py (application/octet-stream)
I have provided a python script in the attachment to minimize the reproduction of the issue. I'm sorry that I lost the attached script in my last reply, but I've added it in this reply. You can also use psql to reproduce it with the following steps: 1. Initialize the data ``` DROP TABLE IF EXISTS tbl_part; CREATE TABLE tbl_part (a integer) PARTITION BY RANGE (a); CREATE TABLE tbl_part_p1 PARTITION OF tbl_part FOR VALUES FROM (0) TO (10); CREATE INDEX ON tbl_part(a); ``` 2. session1 reindex and gdb break at index.c:3585 ``` REINDEX INDEX tbl_part_a_idx; ``` 3. session2 drop index succeed ``` DROP INDEX tbl_part_a_idx; ``` 4. session1 gdb continue Best Regards, Fei Changhong Alibaba Cloud Computing Ltd.