Subject Re: Corrupted database
Author Adam
--- In firebird-support@yahoogroups.com, "kapsee" <kapil.surlaker@...>
wrote:
>
> I am dealing with a corrupted database. isql, gfix or most commands
> error out immediately saying "reached end of file". I get the
> following output from gstat before it quits as well. Any chance I can
> recover any data from this database ?
>
> Thanks for all your help.
>
>
> Database header page information:
> Flags 0
> Checksum 12345
> Generation 936636
> Page size 4096
> ODS version 10.1
> Oldest transaction 936632
> Oldest active 936633
> Oldest snapshot 936633
> Next transaction 936634
> Bumped transaction 1
> Sequence number 0
> Next attachment ID 0
> Implementation ID 16
> Shadow count 0
> Page buffers 0
> Next header page 0
> Database dialect 3
> Creation date Apr 24, 2006 12:15:19
> Attributes
>
> Variable header data:
> *END*
>
>
> Database file sequence:
> File c:\test.fdb is the only file
>
> Database log page information:
> Creation date
> Log flags: 2
> No write ahead log
>
> Next log page: 0
>
> Variable log data:
> Control Point 1:
> File name:
> Partition offset: 0 Seqno: 0 Offset: 0
> Control Point 2:
> File name:
> Partition offset: 0 Seqno: 0 Offset: 0
> Current File:
> File name:
> Partition offset: 0 Seqno: 0 Offset: 0
> *END*
> I/O error for file "C:\TEST.FDB"
> -Error while trying to read from file
> -Reached the end of the file.
>


Burn the database file to a CD / DVD / some other write once media in
case one of your experiments loses data. If gfix and iSQL die
immediately, it is probably more serious than a bad record version,
you may need to contact IBSurgeon.

When everything settles back down, it is worth trying to determine how
the database got corrupted, if it is hardware failure then it is just
a matter of time before the next database goes.

Adam