0

I did an innodb force recovery. I went from 1-> and on 5 MySQL booted up. I was able to do mydqldump.

Customer is now saying some of data is wrong. (References to another table)

Is this possible?

0

I did an innodb force recovery.

Customer is now saying some of data is wrong.

Is this possible?

Short answer: Yes.

Any form of recovery can result in data loss.

Using innodb force recovery, you are telling the DBMS to get that database back up and running any way it can, no matter what that means to the data [that used to be] inside it.

Presumably, you did the force recovery because you had a problem with the database or the server that it runs on?

Your first thought should have been to restore your database from your backups (which, after all, only exist to allow you to do exactly that).

Trying to get MySQL to try and piece together something that may or may not be on the disk any more is a Fool's Errand.

| improve this answer | |
0

Using the value of 5 for innodb_force_recovery will not process undo logs. This can result in data corruption from the perspective of partially completed transactions being persisted (even transactions that ended in error & needed to be rolled back!). I would not expect "surprise" data.

I'm not sure what you mean by "some of data is wrong...references to another table," but if you're referring to foreign keys where the referenced row doesn't exist, that would make sense, as a partially completed (or even partially rolled back) transaction could result in that situation.

From the docs:

5 (SRV_FORCE_NO_UNDO_LOG_SCAN)

Does not look at undo logs when starting the database: InnoDB treats even incomplete transactions as committed. This value can permanently corrupt data files. Sets InnoDB to read-only.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.