repair all mysql tables

mysql -Be "select concat('repair table ', TABLE_SCHEMA, '.', table_name, ';') from information_schema.tables where table_schema<>'information_schema';" | tail -n+2 | mysql

or

mysqlcheck --auto-repair -A

--auto-repair
If a checked table is corrupted, automatically fix it. Any necessary repairs are done after all tables have been checked.

-A
Check all tables in all databases.