Subject | Re: [firebird-support] db corruption |
---|---|
Author | Rik van Kekem |
Post date | 2016-04-05T08:20:34Z |
'Andrew Zenz' andrew@... [firebird-support] wrote:
foreign keys pointing to the 2 corrupt tables?? If they do, that's
probably the reason it failed. If not... what exactly was the error?
I've fixed a few DB's in the past manually but it's tedious work (and
you might loose some records due to corrupt db-pages).
Before pumping over the data from the corrupt DB you need to restore
that DB to a working DB (backup/restore cycle). The DB will be marked as
offline in case of errors but you can reach the data with a single
instance of your DB-manager of choice.
Then you need to remove the records in those tables which depend on the
tables you left out. Or you need to NULL the foreign keys if your
DB-design allows it. After that you should be able to pump the adjusted
tables.
(I even repaired some DB's in place after which I could bring them
online again. And after a backup/restore cycle they were ok to use)
Regards,
Rik
> FYI FirstAID scanned the database and identified 2 tables as havingThe tables on which it failed during the data pump... did they have
> corruption. I attempted a data pump with DBW excluding those 2 tables
> but it failed on several other tables, tables that FirstAID claims are
> clean.
foreign keys pointing to the 2 corrupt tables?? If they do, that's
probably the reason it failed. If not... what exactly was the error?
I've fixed a few DB's in the past manually but it's tedious work (and
you might loose some records due to corrupt db-pages).
Before pumping over the data from the corrupt DB you need to restore
that DB to a working DB (backup/restore cycle). The DB will be marked as
offline in case of errors but you can reach the data with a single
instance of your DB-manager of choice.
Then you need to remove the records in those tables which depend on the
tables you left out. Or you need to NULL the foreign keys if your
DB-design allows it. After that you should be able to pump the adjusted
tables.
(I even repaired some DB's in place after which I could bring them
online again. And after a backup/restore cycle they were ok to use)
Regards,
Rik