1、前台app报错:
2、登陆mysql查询结果:
root:bj85.4bo.cn:)[ecshop]> check table ecs_stats;
+------------------+-------+----------+-------------------------------------------------------+
| Table | Op | Msg_type | Msg_text |
+------------------+-------+----------+-------------------------------------------------------+
| ecshop.ecs_stats | check | warning | Table is marked as crashed and last repair failed |
| ecshop.ecs_stats | check | warning | 1 client is using or hasn't closed the table properly |
| ecshop.ecs_stats | check | warning | Size of indexfile is: 4173824 Should be: 1024 |
| ecshop.ecs_stats | check | error | Record-count is not ok; is 406459 Should be: 0 |
| ecshop.ecs_stats | check | warning | Found 406459 parts Should be: 0 parts |
| ecshop.ecs_stats | check | error | Corrupt |
+------------------+-------+----------+-------------------------------------------------------+
6 rows in set (0.69 sec)
3、修复表:
(root:bj85.4bo.cn:)[ecshop]> repair table ecs_stats
-> ;
+------------------+--------+----------+-----------------------------------------+
| Table | Op | Msg_type | Msg_text |
+------------------+--------+----------+-----------------------------------------+
| ecshop.ecs_stats | repair | warning | Number of rows changed from 0 to 406459 |
| ecshop.ecs_stats | repair | status | OK |
+------------------+--------+----------+-----------------------------------------+
2 rows in set (2.77 sec)
(root:bj85.4bo.cn:)[ecshop]> check table ecs_stats;
+------------------+-------+----------+----------+
| Table | Op | Msg_type | Msg_text |
+------------------+-------+----------+----------+
| ecshop.ecs_stats | check | status | OK |
+------------------+-------+----------+----------+
1 row in set (0.59 sec)
4、查看表结构:
(root:bj85.4bo.cn:)[ecshop]> show create table ecs_stats;
+-----------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| Table | Create Table