Re: Block Corruption issue.. - Mailing list pgsql-general

From Albe Laurenz
Subject Re: Block Corruption issue..
Date
Msg-id A737B7A37273E048B164557ADEF4A58B3660D3C9@ntex2010i.host.magwien.gv.at
Whole thread Raw
In response to Block Corruption issue..  (Sachin Srivastava <Sachin.Srivastava@cyient.com>)
List pgsql-general
Sachin Srivastava wrote:
> Could you help us solving  the below error which we are getting during taking pg_dump.
> 
> pg_dump: SQL command failed
> 
> pg_dump: Error message from server: ERROR:  invalid page header in block 14521215 of relation
> pg_tblspc/18140340/PG_9.1_201105231/18140346/18140757
> 
> pg_dump: The command was: COPY evidence.partline (feature_id, version, base_type_id, domain_class_id,
> domain_subclass_id, status_id, deleted, modification_time, has_children, is_evidence, data_immediate,
> data_lazy, parent_line_id, start_point_id, end_point_id, start_offset, end_offset, geometry) TO
> stdout;

There is a corrupt block in this table.

This is a good starting point:
https://wiki.postgresql.org/wiki/Corruption

If you have a backup, use it!

One simple option is to set "zero_damaged_pages" and then pg_dump
(http://www.postgresql.org/docs/9.4/static/runtime-config-developer.html#GUC-ZERO-DAMAGED-PAGES),
but don't forget that this *will* lose some data.

Yours,
Laurenz Albe

pgsql-general by date:

Previous
From: Tomas Vondra
Date:
Subject: Re: Block Corruption issue..
Next
From: Ramesh T
Date:
Subject: Re: Functions