Re: Zeroing single tuple in data file.

From: Lukasz Brodziak <lukasz(dot)brodziak(at)gmail(dot)com>
To: Matthew Walden <matthew(dot)walden(at)bcs(dot)org>
Cc: pgsql-admin(at)postgresql(dot)org
Subject: Re: Zeroing single tuple in data file.
Date: 2010-11-22 08:56:37
Message-ID: AANLkTikeVV1YUsxqBuBTMS7KD4HrTqt=StebArb1WV48@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

\d+ what do You mean by that?

2010/11/22 Matthew Walden <matthew(dot)walden(at)bcs(dot)org>:
> 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 -
>
> http://blog.endpoint.com/2010/06/tracking-down-database-corruption-with.html
>
> 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 <lukasz(dot)brodziak(at)gmail(dot)com>
> wrote:
>>
>> 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...
>

--
Łukasz Brodziak
"What if everyting around You isn't quite as it seems,
What if all the world You think You know is an inelaborate dream
When You look at Your reflection is that all you want it to be
What if You could look right through the cracks
Would You find Yourself...... Find Yourself afraid to see"

In response to

Responses

Browse pgsql-admin by date

  From Date Subject
Next Message Matthew Walden 2010-11-22 09:00:49 Re: Zeroing single tuple in data file.
Previous Message Matthew Walden 2010-11-22 08:54:14 Re: Zeroing single tuple in data file.