0

MySQLTuner 中的建议嗨,我已经运行了 MySQLTuner - perl,我接受了

安全建议

Warning: Using unique option prefix pass instead of password is deprecated and will be removed in a future release. Please use the full name instead.
[OK] All database users have passwords assigned
Warning: Using unique option prefix pass instead of password is deprecated and will be removed in a future release. Please use the full name instead.

性能指标

[--] Up for: 22m 28s (463K q [344.006 qps], 1K conn, TX: 857M, RX: 90M)
[--] Reads / Writes: 99% / 1%
[--] Total buffers: 168.0M global + 2.8M per thread (151 max threads)
[OK] Maximum possible memory usage: 583.2M (1% of installed RAM)
[OK] Slow queries: 0% (0/463K)
[OK] Highest usage of available connections: 12% (19/151)
[OK] Key buffer size / total MyISAM indexes: 8.0M/146.0M
[OK] Key buffer hit rate: 100.0% (184M cached / 55K reads)
[!!] Query cache is disabled
[OK] Sorts requiring temporary tables: 0% (34 temp sorts / 738K sorts)
[!!] Joins performed without indexes: 543
[OK] Temporary tables created on disk: 23% (30K on disk / 131K total)
[!!] Thread cache is disabled
[!!] Table cache hit rate: 0% (400 open / 58K opened)
[OK] Open file limit used: 0% (759/500K)
[OK] Table locks acquired immediately: 99% (842K immediate / 842K locks)
[OK] InnoDB buffer pool / data size: 128.0M/92.3M
[OK] InnoDB log waits: 0

建议

Run OPTIMIZE TABLE to defragment tables for better performance
    MySQL started within last 24 hours - recommendations may be inaccurate
    Enable the slow query log to troubleshoot bad queries
    Adjust your join queries to always utilize indexes
    Set thread_cache_size to 4 as a starting value
    Increase table_open_cache gradually to avoid file descriptor limits
    Read this before increasing table_open_cache over 64: 

要调整的变量:

query_cache_size (>= 8M)
join_buffer_size (> 128.0K, or always use indexes with joins)
thread_cache_size (start at 4)
table_open_cache (> 400)

服务器运行了 48gb 和 i7 cpu 在 my.cnf 我有

[mysqld]
max_allowed_packet=268435456
open_files_limit=500000
local-infile=0

有什么建议么 ?

4

1 回答 1

0

您应该使用 github 上最新版本的 mysqltuner。

Mysqltuner 说:MySQL 在过去 24 小时内启动 - 建议可能不准确

您应该在较长时间后使用 mysqltuner。

于 2015-08-24T09:55:56.567 回答