| 1 | = Corrupte InnoDB database = |
| 2 | |
| 3 | Dit type database heeft geen repair functie, daar deze een journal heeft. Repairen is normaal niet nodig. |
| 4 | |
| 5 | De database kan echter wel corrupt raken door defecte hardware en harddisken. Let vooral op als u S.M.A.R.T. errors krijgt! |
| 6 | |
| 7 | Indien u database niet meer start door een InnoDB corruptie ziet u de volgende meldingen in de logs |
| 8 | {{{ |
| 9 | # less /home/system/mysql5/darkstar.err |
| 10 | InnoDB: Page checksum 673831230, prior-to-4.0.14-form checksum 3511409578 |
| 11 | InnoDB: stored checksum 343549968, prior-to-4.0.14-form stored checksum 2720139525 |
| 12 | InnoDB: Page lsn 0 3852576933, low 4 bytes of lsn at page end 67108992 |
| 13 | InnoDB: Page number (if stored to page already) 3, |
| 14 | InnoDB: space id (if created with >= MySQL-4.1.1 and stored already) 0 |
| 15 | InnoDB: Database page corruption on disk or a failed |
| 16 | InnoDB: file read of page 3. |
| 17 | InnoDB: You may have to recover from a backup. |
| 18 | InnoDB: It is also possible that your operating |
| 19 | InnoDB: system has corrupted its own file cache |
| 20 | InnoDB: and rebooting your computer removes the |
| 21 | InnoDB: error. |
| 22 | InnoDB: If the corrupt page is an index page |
| 23 | InnoDB: you can also try to fix the corruption |
| 24 | InnoDB: by dumping, dropping, and reimporting |
| 25 | InnoDB: the corrupt table. You can use CHECK |
| 26 | InnoDB: TABLE to scan your table for corruption. |
| 27 | InnoDB: See also InnoDB: http://dev.mysql.com/doc/refman/5.0/en/forcing-recovery.html |
| 28 | InnoDB: about forcing recovery. |
| 29 | InnoDB: Ending processing because of a corrupt database page. |
| 30 | InnoDB: Database page corruption on disk or a failed |
| 31 | InnoDB: file read of page 3. |
| 32 | InnoDB: You may have to recover from a backup. |
| 33 | 101210 12:40:17 InnoDB: Page dump in ascii and hex (16384 bytes): |
| 34 | }}} |
| 35 | |
| 36 | |
| 37 | == Handmatig de database herstellen == |
| 38 | |
| 39 | We volgen de instructies op http://dev.mysql.com/doc/refman/5.0/en/forcing-recovery.html. |
| 40 | |
| 41 | * Zet de database uit en alle services die deze gebruiken |
| 42 | |
| 43 | {{{ |
| 44 | # svc -d /service/mysql |
| 45 | # svc -d /service/zarafa-server |
| 46 | }}} |
| 47 | |
| 48 | * Voeg innodb_force_recovery = 4 toe en herstart database in recovery mode. |
| 49 | {{{ |
| 50 | # mcedit /etc/my.cnf |
| 51 | # svc -u /sevice/mysql |
| 52 | # less /home/system/mysql5/darkstar.err |
| 53 | |
| 54 | 101210 12:40:17 InnoDB: Started; log sequence number 0 4081822057 |
| 55 | InnoDB: !!! innodb_force_recovery is set to 4 !!! |
| 56 | }}} |
| 57 | |
| 58 | |
| 59 | |