- 论坛徽章:
- 0
|
本帖最后由 cenalulu 于 2012-11-05 13:27 编辑
#add by cenalulu: 解决方案见6楼
我们mysql服务器,用的主从。 而从服务器主要是 查询。
以下是我们从服务器的 慢查询 记录。使用mysqlsla工具得到的结果其中一条。
代码:
Count : 2.12k (8.35%)
Time : 2120 s total, 1.002364 s avg, 1 s to 2 s max (7.86%)
95% of Time : 2009 s total, 1 s avg, 1 s to 1 s max
Lock Time (s) : 0 total, 0 avg, 0 to 0 max (0.00%)
95% of Lock : 0 total, 0 avg, 0 to 0 max
Rows sent : 1 avg, 1 to 1 max (0.05%)
Rows examined : 0 avg, 0 to 0 max (0.00%)
Database : aaabbbccc
Users :
jc001@ 192.168.0.101 : 39.81% (842) of query, 40.29% (10207) of all users
jc001@ 192.168.0.102 : 35.04% (741) of query, 32.57% (8251) of all users
jc001@ 192.168.0.103 : 25.15% (532) of query, 24.35% (6167) of all users
Query abstract:
SELECT * FROM shop_detail WHERE shop_id = N LIMIT N;
Query sample:
SELECT * FROM shop_detail WHERE shop_id = 1333912 LIMIT 1;
我实在看不出这条语句有什么问题,会被记录进慢日志,还请大家帮帮,谢谢。。 |
|