New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Firebird cannot open a database after a power loss [CORE3235] #1285
Comments
Commented by: Gili Buzaglo (gland) Output of gstat ih is:
|
Modified by: Gili Buzaglo (gland)Attachment: corrupted.cmr [ 11820 ] |
Commented by: Gili Buzaglo (gland) corrupted db is attached |
Commented by: @dyemanov Can ISQL connect or does it also fail with the same error? |
Commented by: Greg (greg) Did you try a backup./restore ? |
Commented by: Gili Buzaglo (gland) Hi |
Commented by: Greg (greg) Well, we've been using from Interbase 4 to Firebird 2.0 and never lost a database. Even if sometimes gfix -mend was not enough to recover the database. GFIX always did the job so far... |
Commented by: Gili Buzaglo (gland) database engine should be immune to sudden power losses and thanks |
Commented by: Gili Buzaglo (gland) BTw |
Commented by: @dyemanov Generally speaking, it's impossible to guarantee any reliability in the environment you cannot control. For example, no transaction log (or any alternative) can protect you against a storage controller with a write-through cache turned on but without the battery inside. |
Commented by: Sean Leyne (seanleyne) In addition to the other comments, I would also ask if Forced Writes is turned on for the database? |
Commented by: Gili Buzaglo (gland) for dimitry: for sean: Thanks guys |
Commented by: Gili Buzaglo (gland) hi |
Commented by: @dyemanov Commented by Vlad Khorsun: > Is it possible that attributes are not valid when the db gets corrupted? > > I ask this because all ower dbs are created with fw=true. |
Commented by: Gili Buzaglo (gland) I've attached a new file. Same problem (although this time the exception is a bit different).... jbird throws an exceptoin: you can see that gstat -h shows force write is on. /usr/local/firebird/bin/gstat -h /var/opt/CLLF/db/cmr.gdb Database "/var/opt/CLLF/db/cmr.gdb"
|
Modified by: Gili Buzaglo (gland)Attachment: corrupted26-12.gdb [ 11854 ] |
Commented by: Gili Buzaglo (gland) A correction to last comment: gstat -h output: /usr/local/firebird/bin/gstat -h /var/opt/CLLF/db/cmr_old.gdb Database "/var/opt/CLLF/db/cmr_old.gdb"
|
Commented by: Gili Buzaglo (gland) This attachement is a correction to previous attachement |
Modified by: Gili Buzaglo (gland)Attachment: corrupted26-12.gdb [ 11855 ] |
Commented by: @hvlad Error "page 3 is of wrong type (expected 4, found 0)" means that first pointer page is corrupted. This all looks very strange for me. The fact that whole page is filled by zeros make me think about HW (or driver) issues. Your last comment again contains stats from *another* database. It didn't make easier for us to understand the issue... |
Commented by: @hvlad The latest attach contains corrupted database. If you'll validate it you'll see following errors
Database can be backed up and restored without a problem. What do you do with database ? |
Commented by: Gili Buzaglo (gland) hi This problem only occurs when we shutdown the machine, but also on rare ocasions. cc3r5 (Client) Sun Dec 26 10:29:16 2010 |
Commented by: Gili Buzaglo (gland) on one of the corruptions after shutdown I tries to use gfix and gbak and restore. I've attached the file. Please any help appriciated |
Modified by: Gili Buzaglo (gland)Attachment: unrestorable.gbk.gz [ 11894 ] |
Submitted by: Gili Buzaglo (gland)
Is duplicated by CORE3113
Attachments:
corrupted.cmr
corrupted26-12.gdb
corrupted26-12.gdb
unrestorable.gbk.gz
Power failre occus during normal work with a database.
Application cannot connect to the database after power is restored.
We get the following exceptions:
org.firebirdsql.jdbc.FBSQLException: GDS Exception. 335544333. internal gds software consistency check (can't continue after bugcheck)
at org.firebirdsql.jdbc.AbstractPreparedStatement.<init>(AbstractPreparedStatement.java:127)
at org.firebirdsql.jdbc.FBPreparedStatement.<init>(FBPreparedStatement.java:41)
at sun.reflect.GeneratedConstructorAccessor3.newInstance(Unknown Source)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
at java.lang.reflect.Constructor.newInstance(Unknown Source)
at org.firebirdsql.jdbc.FBStatementFactory.createPreparedStatement(FBStatementFactory.java:90)
org.firebirdsql.jdbc.FBSQLException: GDS Exception. 335544333. internal gds software consistency check (cannot find record fragment (248), file: dpm.cpp line: 1181)
at org.firebirdsql.jdbc.FBStatementFetcher.fetch(FBStatementFetcher.java:206)
at org.firebirdsql.jdbc.FBStatementFetcher.next(FBStatementFetcher.java:119)
at org.firebirdsql.jdbc.AbstractResultSet.next(AbstractResultSet.java:250)
at cloverleaf.manager.mbe.rm.volume.PeriodicReplicationManager.readData(PeriodicReplicationManager.java:106)
at cloverleaf.manager.mbe.rm.volume.PeriodicReplicationManager.run(PeriodicReplicationManager.java:503)
and later
at org.firebirdsql.gds.GDSException: internal gds software consistency check (cannot find record fragment (248), file: dpm.cpp line: 1181)
at org.firebirdsql.gds.impl.wire.AbstractJavaGDSImpl.readStatusVector(AbstractJavaGDSImpl.java:2169)
at org.firebirdsql.gds.impl.wire.AbstractJavaGDSImpl.receiveResponse(AbstractJavaGDSImpl.java:2119)
at org.firebirdsql.gds.impl.wire.AbstractJavaGDSImpl.iscDsqlFetch(AbstractJavaGDSImpl.java:1350)
at org.firebirdsql.gds.impl.GDSHelper.fetch(GDSHelper.java:264)
at org.firebirdsql.jdbc.FBStatementFetcher.fetch(FBStatementFetcher.java:201)
at org.firebirdsql.jdbc.FBStatementFetcher.next(FBStatementFetcher.java:119)
at org.firebirdsql.jdbc.AbstractResultSet.next(AbstractResultSet.java:250)
at cloverleaf.manager.mbe.rm.volume.PeriodicReplicationManager.readData(PeriodicReplicationManager.java:106)
at cloverleaf.manager.mbe.rm.volume.PeriodicReplicationManager.run(PeriodicReplicationManager.java:503)
Aug 22, 2010 4:37:48 AM cloverleaf.manager.database.db.SqlConnectionPool$Pool returnConnection();
The text was updated successfully, but these errors were encountered: