Re: BUG #5984: Got FailedAssertion("!(opaque->btpo_prev == target)", File: "nbtpage.c", Line: 1166) - Mailing list pgsql-bugs

From Robert Haas
Subject Re: BUG #5984: Got FailedAssertion("!(opaque->btpo_prev == target)", File: "nbtpage.c", Line: 1166)
Date
Msg-id BANLkTi=kvx7Xd0vAU9zLhnWhFSbAJnFYJg@mail.gmail.com
Whole thread Raw
In response to Re: BUG #5984: Got FailedAssertion("!(opaque->btpo_prev == target)", File: "nbtpage.c", Line: 1166)  (Pascal Borschneck <borschneck@hotmail.com>)
List pgsql-bugs
On Wed, May 25, 2011 at 4:06 AM, Pascal Borschneck
<borschneck@hotmail.com>wrote:

>  Global question as I didn't find it: are "ERROR:   duplicate key value
> violates unique constraint" fatal errors ? As they may (most of the time)
> be corrected with reindexdb --all
> Someone told me some weeks ago "*it's only a notice, the database is not
> corrupted*" ...
>

Well, if you get that error, then that either means that the index is
confused (it has duplicate index pointers for the same value when it really
shouldn't) or that the table is confused (it has duplicate rows with the
supposedly unique value when it shouldn't).  In the first case, a REINDEX
will fix it; in the second case, your data is corrupt.

But even your indexes really shouldn't be getting corrupted if everything is
working properly.  Are you running with fsync=off?  If not, you probably
want to check your drive write caches and the integrity of your hardware.
This kind of thing usually means that corruption is happening somewhere, and
if you don't track it down and fix it, eventually it will probably add up to
something serious.

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

pgsql-bugs by date:

Previous
From: Robert Haas
Date:
Subject: Re: BUG #6041: Unlogged table was created bad in slave node
Next
From: Robert Haas
Date:
Subject: Re: BUG #6042: unlogged table with Streaming Replication