Page 1 of 1

MyISAM-table '/var/lib/mysql/zm/Frames.MYI' is not fixed bec

Posted: Wed May 09, 2007 10:54 am
by jameswilson

Code: Select all

 myisamchk -f  /var/lib/mysql/*/Frames.MYI -f
Checking MyISAM file: /var/lib/mysql/zm/Frames.MYI
Data records: 4805800   Deleted blocks:       0
myisamchk: warning: Table is marked as crashed and last repair failed
- check file-size
myisamchk: warning: Size of indexfile is: 245637120      Should be: 88667136
myisamchk: warning: Size of datafile is: 194880000       Should be: 144174000
- check record delete-chain
- check key delete-chain
- check index reference
- check data record references index: 1
- check data record references index: 2
- check data record references index: 3
myisamchk: error: Can't read indexpage from filepos: -1
- recovering (with sort) MyISAM-table '/var/lib/mysql/zm/Frames.MYI'
Data records: 4805800
- Fixing index 1
- Fixing index 2
- Fixing index 3
myisamchk: Error writing file '/var/lib/mysql/zm/Frames.MYI' (Errcode: 5)
myisamchk: error: 5 when fixing table
MyISAM-table '/var/lib/mysql/zm/Frames.MYI' is not fixed because of errors
Try fixing it by using the --safe-recover (-o), the --force (-f) option or by not using the --quick (-q) flag
Cant fix this, tried mysqlcheck and myisamchk, any pointers?

Posted: Thu May 10, 2007 7:26 am
by maclellan
It's simple - dont use myisam, but instead use innodb. This can be done my modifyng the SQL database creation script with 'engine = INNODB'. you can search the mysql site for more info on this.

Posted: Thu May 10, 2007 1:34 pm
by jameswilson
really im intrieged
id like a script that could be cron'd and do this repair all the time. this one was beyond repair and cordel had to explain dropping tables to me.