2014-04-14 77 views
0

我是新來的stackoverflow,所以這是我的第一槍:)mysqltuner - 需要臨時表的排序

我有我的Mysql數據庫的問題。我遇到了一些性能問題,所以我決定使用mysqltuner。結果是

[--] Up for: 7m 42s (7K q [16.452 qps], 78 conn, TX: 927K, RX: 2M) 
[--] Reads/Writes: 86%/14% 
[--] Total buffers: 2.1G global + 1.1M per thread (151 max threads) 
[OK] Maximum possible memory usage: 2.3G (24% of installed RAM) 
[OK] Slow queries: 0% (16/7K) 
[OK] Highest usage of available connections: 2% (4/151) 
[OK] Key buffer size/total MyISAM indexes: 1.0G/834.4M 
[OK] Key buffer hit rate: 99.1% (8M cached/79K reads) 
[!!] Query cache efficiency: 0.0% (0 cached/4K selects) 
[OK] Query cache prunes per day: 0 
[!!] Sorts requiring temporary tables: 376% (2K temp sorts/675 sorts) 
[OK] Temporary tables created on disk: 0% (13 on disk/7K total) 
[OK] Thread cache hit rate: 94% (4 created/78 connections) 
[OK] Table cache hit rate: 26% (102 open/384 opened) 
[OK] Open file limit used: 1% (63/5K) 
[OK] Table locks acquired immediately: 100% (13K immediate/13K locks) 

顯然我有太多的臨時表創建。

但這是什麼意思?這個問題是由缺少索引還是其他問題引起的?

我很感激任何幫助。

謝謝

+0

您在非索引列上使用了'ORDER BY'。 – h2ooooooo

+0

所有列都被編入索引。但我有一些查詢是由一個'SUM()'子句排序。這是否也會導致這個問題? – user3531962

回答