mysql error 134

转自: http://hi.baidu.com/jishachengqiu/item/b347de5a0dafb519db163527

Request Method: GET Request URL: http://disk.cnlife365.com/zh-cn/manage/ Exception Type: TypeError Exception Value: unsubscriptable object Exception Location: /usr/lib/python2.4/site-packages/django/db/models/query.py in sum, line 215 django 0.96 + mysql做一个简单的应用,出现下列提示:
Request Method: GET 
Request URL: http://localhost/zh-cn/manage/ 
Exception Type: TypeError 
Exception Value: unsubscriptable object 
Exception Location: /usr/lib/python2.4/site-packages/django/db/models/query.py in sum, line 215

在shell下查到是执行了select sum(file_size) from files_virtualfile,进入mysql,执行上述语句,
mysql> SELECT SUM(file_size) FROM `files_virtualfile`;
出现错误提示: ERROR 1030 (HY000): Got error 134 from storage engine

退出mysql,用perror查了一下134错误:

[root@localhost wwwroot]# perror 134
MySQL error code 134: Record was already deleted (or record file crashed)

应该是Table表文件有坏块了:

进入MySQL的命令行,运行 Repair Table files_virtualfile; 
显示如下提示:

mysql> repair table files_virtualfile;
+-----------------------------+--------+----------+----------+
| Table                       | Op     | Msg_type | Msg_text |
+-----------------------------+--------+----------+----------+
| fs2you_sx.files_virtualfile | repair | status   | OK       |
+-----------------------------+--------+----------+----------+
1 row in set (0.06 sec)

再次进入manage页面,提示成功。

你可能感兴趣的:(mysql error 134)