查看Mysql数据库日志:/var/log/mysqld.log,发现存在以下日志内容:
[ERROR] [MY-013134] [Server] Table './TestDB/TestTable1' is marked as crashed and should be repaired
解决方法:
# mysql -uroot -p
# use TestDB;
# check table TestTable1;
mysql> check table TestTable1;
+---------------------------+-------+----------+-----------------------------------------------------------+
| Table | Op | Msg_type | Msg_text |
+---------------------------+-------+----------+-----------------------------------------------------------+
| TestDB.TestTable1 | check | warning | Table is marked as crashed |
| TestDB.TestTable1 | check | warning | 14 clients are using or haven't closed the table properly |
| TestDB.TestTable1 | check | error | Record at pos: 278780 is not remove-marked |
| TestDB.TestTable1 | check | error | record delete-link-chain corrupted |
| TestDB.TestTable1 | check | error | Corrupt |
+---------------------------+-------+----------+-----------------------------------------------------------+
5 rows in set (0.01 sec)
#repair table Test_Table;
mysql> check table Test_Table;
+---------------------------+-------+----------+----------+
| Table | Op | Msg_type | Msg_text |
+---------------------------+-------+----------+----------+
| TestDB.TestTable1 | check | status | OK |
+---------------------------+-------+----------+----------+
1 row in set (0.00 sec)