[client]
port=3306
socket=/tmp/mysql.sock
[mysqld]
user = mysql #使用mysql帐户启动
basedir = /app/mysql
datadir = /app/mysql/data
port=3306
server-id = 1
socket=/tmp/mysql.sock
character-set-server = utf8
general_log = 1
skip-name-resolve
back_log = 300
max_connections = 1000
max_connect_errors = 6000
open_files_limit = 65535
table_open_cache = 128
max_allowed_packet = 4M
binlog_cache_size = 1M
max_heap_table_size = 8M
tmp_table_size = 16M
read_buffer_size = 2M
read_rnd_buffer_size = 8M
sort_buffer_size = 8M
join_buffer_size = 28M
key_buffer_size = 4M
thread_cache_size = 8
query_cache_type = 1
query_cache_size = 8M
query_cache_limit = 2M
ft_min_word_len = 4
log_bin = mysql-bin
binlog_format = mixed
expire_logs_days = 30
performance_schema = 0
explicit_defaults_for_timestamp
myisam_sort_buffer_size = 8M
myisam_repair_threads = 1
interactive_timeout = 28800
wait_timeout = 28800
symbolic-links=0
sql_mode=NO_ENGINE_SUBSTITUTION,NO_AUTO_CREATE_USER,STRICT_TRANS_TABLES
原文地址:http://blog.51cto.com/12965094/2163452