And the \d+ on users? Also would you mind pasting the output exactly as it
is appears on screen, assuming it is in English?
I'm trying to build up a picture here of how many problems you have and
whether they can be fixed conventionally with the database interface or
whether you need to start messing around with the data files. If the case
is the latter, you won't be able to just remove the single rows that are
causing the problem - you will loose full pages. It could be that it is
actually a corrupt index rather than the table - in this case the \d+ will
help me assist you in disabling that index.
You can take a look at this guide if you suspect block corruption -
BUT I would try everything else first. You will loose data if you follow
that approach (but it may not be avoidable). If your database is a
production one (I don't know the environment you are using this database in)
then this would need to be a last ditch attempt to salvage otherwise lost
data. In any case it sounds like you have some kind of hardware issue and
should consider a full backup restore if possible and then afterwards
running frequent ANALYZE; commands to quickly detect further corruptions.
On Mon, Nov 22, 2010 at 7:36 AM, Lukasz Brodziak
> And the version is 8.2.4
> 2010/11/22 Lukasz Brodziak <lukasz(dot)brodziak(at)gmail(dot)com>:
> > Hello,
> > I got access to corrupted DB... The SELECT COUNT(*) FROM users where
> > id_usr IS NULL returned error of invalid page header in one of the
> > blocks...
In response to
pgsql-admin by date
|Next:||From: Lukasz Brodziak||Date: 2010-11-22 08:56:37|
|Subject: Re: Zeroing single tuple in data file.|
|Previous:||From: Khangelani Gama||Date: 2010-11-22 08:30:49|
|Subject: Postgres database : Out of balance problem from the same table |