/etc/init.d/mysqld stopDon't forget to lsof and check for any hanging processes or inode access.
lsof |grep mysqlThen go to the directory in which you have your mysql database files, say
/var/lib/mysqlWithin the directory, check the tables:
myisamchk *.MYIThen repair the tables:
myisamchk -r *.MYIAfter all is said and done, restart mysql...
/etc/init.d/mysqld startA caveat, however, you need to have as much disk space free on the disk on which you have your database that you're doing your repairs. So, if you have a 50GB database, you'll need to have at least 50GB free. Oh yes. However, if you want to play it fast and loose and do a live check, use mysqlcheck.
mysqlcheck dbThen repair the database tables:
mysqlcheck -r db