public inbox for [email protected]
help / color / mirror / Atom feedFrom: Adrian Klaver <[email protected]>
To: Wim Rouquart <[email protected]>
To: [email protected] <[email protected]>
Subject: Re: Index (primary key) corrupt?
Date: Thu, 18 Sep 2025 09:01:18 -0700
Message-ID: <[email protected]> (raw)
In-Reply-To: <AS2PR05MB1075477BA334D4DA262AD75BFEF16A@AS2PR05MB10754.eurprd05.prod.outlook.com>
References: <AS2PR05MB1075477BA334D4DA262AD75BFEF16A@AS2PR05MB10754.eurprd05.prod.outlook.com>
On 9/18/25 05:25, Wim Rouquart wrote:
> Internal
>
>
> Hello,
>
> When doing a pg_dump of one of our databases one of the tables primary
> keys doesn’t get exported. Pg_dump just skips this index, without any
> warning whatsoever (verbose mode was used to doublecheck).
What is the complete table definition?
What is the complete pg_dump command being given?
Is the PK definition in the pg_dump file?
For plain text format can you grep/find it?
For custom format does:
pg_restore -s -t <the_table> <dump_file>
show it?
How is the dump file being restored?
>
> When doing a REINDEX the issue is fixed.
>
> As this seems to me to be some form of index corruption, I tried using
> amcheck (bt_index_check and bt_index_parent_check) to verify for
> corruption but both resulted with no issues (the index is a btree).
>
> I would expect the corruption to show up when using amcheck, am I
> hitting some kind of bug here?
>
> Are there any other ways to doublecheck for corruption (without enabling
> checksum upfront)?
>
> This concerns a PostgreSQL version 15 btw.
>
> Thanks!
>
>
> Disclaimer <https://www.kbc.com/KBCmailDisclaimer;
--
Adrian Klaver
[email protected]
reply
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: [email protected]
Cc: [email protected], [email protected], [email protected]
Subject: Re: Index (primary key) corrupt?
In-Reply-To: <[email protected]>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox