first  Cd /var/lib/mysql/  then select the DB need to repaired..

cd database name/
ls
Then Execute the command,

myisamchk -o  -f  tablename  (TO CHECK THE TABLES ASSOCIATED WITH DB)

Eg:myisamchk -o -f   tablename   Eg,  myisamchk -o -f abc.MYI
myisamchk -r  *.MYI (TO CHECK ALL THE TABLES ACSSOCIATED WITH THE DB)

shell> myisamchk [options] tbl_name

shell> myisamchk *.MYI

shell> myisamchk /path/to/database_dir/*.MYI

shell> myisamchk  –silent  –force  –fast  –update-state
           –key_buffer_size=64M  –sort_buffer_size=64M
           –read_buffer_size=1M –write_buffer_size=1M
          /path/to/datadir/*/*.MYI

The recommended way to quickly check all MyISAM tables is:

shell> myisamchk –silent –fast /path/to/datadir/*/*.MYI

You can even check all tables in all databases by specifying a wildcard with the path to the MySQL data directory:

shell> myisamchk /path/to/datadir/*/*.MYI

If you are not in the database directory, you can check all the tables there by specifying the path to the directory:

shell> myisamchk /path/to/database_dir/*.MYI

Important

You must ensure that no other program is using the tables while you are running myisamchk. The most effective means of doing so is to shut down the MySQL server while running myisamchk, or to lock all tables that myisamchk is being used on.