当前位置:数据库 > MySQL >>

跪求Mysql高手指点,Drupal的数据库,数据库CPU使用率经常百分之100多,双核CPU,4G内存(在线等)

这是数据库的慢查询日志,一天100M的日志文件,基本都是如下内容,是不是我的索引没有做好,我并不怎么懂数据库,请不吝指点,恭喜发财!!! # User@Host: AAA[AAA] @ localhost [] # Query_time: 8.846912 Lock_time: 0.000145 Rows_sent: 8 Rows_examined: 108836SET timestamp=1340610103;SELECT DISTINCT r.nid, MATCH(r.body, r.title) AGAINST ('文章内容文章内容文章内容文章内容文章内容') AS score FROM node_revisions r INNER JOIN node n ON r.nid = n.nid AND r.vid = n.vid INNER JOIN node_access na ON na.nid = n.nid WHERE (na.grant_view >= 1 AND ((na.gid = 0 AND na.realm = 'all') OR (na.gid = 1 AND na.realm = 'term_access'))) AND ( n.status <> 0 AND r.nid <> 20346 AND n.type IN ('forum') )GROUP BY n.nid HAVING score > 0 ORDER BY score DESC, r.vid DESC LIMIT 0, 8;
Oracle
MySQL
Access
SQLServer
DB2
Excel
SQLite
SYBASE
Postgres
如果你遇到数据库难题:
请访问www.zzzyk.com 试试
CopyRight © 2012 站长网 编程知识问答 www.zzzyk.com All Rights Reserved
部份技术文章来自网络,