# InnoDB: Database page corruption on disk or a failed file read of page [page id: space=123, page number=456]. You may have to recover from a backup.

- **ID:** `database/mysql-innodb-redo-log-corruption`
- **Domain:** database
- **Category:** data_error
- **Verification:** ai_generated
- **Fix Rate:** 70%

## Root Cause

InnoDB detected a checksum mismatch on a data page, indicating physical corruption of the ibd file or a failed read due to hardware issues (e.g., bad disk sector, memory corruption).

## Version Compatibility

| Version | Status | Introduced | Deprecated |
|---------|--------|------------|------------|
| MySQL 8.0 | active | — | — |
| MySQL 8.4 | active | — | — |
| Percona Server 8.0 | active | — | — |

## Workarounds

1. **Set innodb_force_recovery to a value between 1 and 6 in my.cnf, then restart MySQL to bypass the corruption and dump the table: mysqldump -u root mydb my_table > dump.sql. After dump, drop and recreate the table, then restore. Example: innodb_force_recovery = 4.** (75% success)
   ```
   Set innodb_force_recovery to a value between 1 and 6 in my.cnf, then restart MySQL to bypass the corruption and dump the table: mysqldump -u root mydb my_table > dump.sql. After dump, drop and recreate the table, then restore. Example: innodb_force_recovery = 4.
   ```
2. **Restore the affected table from a recent backup using mysqlbinlog or physical backup (e.g., Percona XtraBackup). Example: xtrabackup --prepare --target-dir=/backup; then copy the restored ibd file to the datadir.** (85% success)
   ```
   Restore the affected table from a recent backup using mysqlbinlog or physical backup (e.g., Percona XtraBackup). Example: xtrabackup --prepare --target-dir=/backup; then copy the restored ibd file to the datadir.
   ```

## Dead Ends

- **Restart MySQL without any recovery steps, hoping the corruption is transient** — InnoDB will attempt to read the corrupted page again during startup or on access, causing the same error or a crash. (95% fail)
- **Run REPAIR TABLE on the affected table** — REPAIR TABLE only works for MyISAM tables; for InnoDB, it returns 'The storage engine for the table doesn't support repair'. (100% fail)
