MySQL数据库常见调优方法及参数设置(二)
58
# socket = .....
59
60
# Remove leading # to set options mainly useful for reporting servers.
61
# The server defaults are faster for transactions and fast SELECTs.
62
# Adjust sizes as needed, experiment to find the optimal values.
63
# join_buffer_size = 128M
64
# sort_buffer_size = 2M
65
# read_rnd_buffer_size = 2M
66
67
# slow_query_log = 1
68
# slow_query_log_file = slow.log
69
# long_query_time = 1
70
# log_queries_not_using_indexes
71
72
# log-bin = mysql-bin
73
# server-id = 1
74
# innodb_flush_log_at_trx_commit = 1
75
# sync_binlog = 1
76
77
sql_mode=NO_ENGINE_SUBSTITUTION,STRICT_TRANS_TABLES
附上 MySQL 5.6.10 编译参数:
1
tar zxvf mysql-5.6.10.tar.gz
2
cd mysql-5.6.10
3
cmake . -DCMAKE_INSTALL_PREFIX=/usr/local/mysql -DWITH_INNOBASE_STORAGE_ENGINE=1 -DMYSQL_TCP_PORT=3306 -DDEFAULT_CHARSET=utf8 -DDEFAULT_COLLATION=utf8_general_ci -DWITH_DEBUG=0 -DCURSES_LIBRARY=/usr/lib64/libncurses.so -DCURSES_INCLUDE_PATH=/usr/include
4
make
5
make install