Re: Fwd: index corruption in PG 8.3.13

From: Nikhil Sontakke <nikhil(dot)sontakke(at)enterprisedb(dot)com>
To: Greg Stark <gsstark(at)mit(dot)edu>
Cc: Alvaro Herrera <alvherre(at)commandprompt(dot)com>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Fwd: index corruption in PG 8.3.13
Date: 2011-03-10 00:24:30
Message-ID: AANLkTincXZsrWOcghjcqba7xcwCfM7kYck-v-zdgN7od@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

>
> What does stat say for the index data file? Are the Size and Blocks
> values the same (modulo block size)? Or are these blocks actually not
> allocated?
>
stat 58401
File: `58401'
Size: 4300800 Blocks: 8400 IO Block: 4096 regular file
Device: 801h/2049d Inode: 13901264 Links: 1

modulo 8192 it gives 525 which is the number of blocks that we see.

> Postgres always forces blocks to be allocated but if they were lost
> due to filesystem corruption maybe they're not allocated any more.
>

Actually these blocks are like a big hole in between. Blocks 279 to
518 are zeroed out and then 519 to 524 is index data. Number 523 is
the one which has been zeroed out too causing all the mayhem.

Regards,
Nikhils

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message David Fetter 2011-03-10 00:32:30 Re: Fwd: psql include file using relative path
Previous Message Greg Stark 2011-03-10 00:14:40 Re: Fwd: index corruption in PG 8.3.13