[mysql]
port=3306
socket=/var/lib/mysql/mysql.sock
default-character-set = utf8mb4
[mysqld]
server-id = 1
datadir=/data/mysql
socket=/var/lib/mysql/mysql.sock
log-bin=mysql-bin
log-slave-updates
slow_query_log_file=/data/mysql/slow.log
binlog_format=mixed
slow_query_log
long_query_time=5
wait_timeout=86400
interactive_timeout=86400
max_connections=1000
max_user_connections=1000
max_connect_errors=20
character_set_server=utf8
skip-external-locking
key_buffer_size = 512M
max_allowed_packet = 512M
table_open_cache = 500
sort_buffer_size = 512M
read_buffer_size = 512M
read_rnd_buffer_size = 512M
myisam_sort_buffer_size = 512M
thread_cache_size = 32
query_cache_size = 512M
group_concat_max_len = 4294967295
#binlog-ignore-db=mysql
binlog-ignore-db=information_schema
#replicate_ignore_db=mysql
replicate_ignore_db=information_schema
expire-logs-days=10
#skip-slave-start
skip-name-resolve
lower_case_table_names=1
log_bin_trust_function_creators=1
#innodb_data_home_dir=/data/mysql/data
#innodb_log_group_home_dir=/data/mysql/logs
innodb_data_file_path=ibdata1:20M:autoextend
innodb_buffer_pool_size=48G
innodb_log_file_size=512M
innodb_log_buffer_size=512M
innodb_lock_wait_timeout=50
#innodb_file_per_table
innodb_flush_log_at_trx_commit=1
explicit_defaults_for_timestamp=true
sql_mode=STRICT_TRANS_TABLES,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION,NO_AUTO_VALUE_ON_ZERO
#lxc加的2016-10-27
character-set-client-handshake = FALSE
character-set-server = utf8mb4
collation-server = utf8mb4_unicode_ci
init_connect='SET NAMES utf8mb4'
#end
# Disabling symbolic-links is recommended to prevent assorted security risks
symbolic-links=0
# Recommended in standard MySQL setup
#sql_mode=NO_ENGINE_SUBSTITUTION,STRICT_TRANS_TABLES
event_scheduler = 1
[mysqld_safe]
log-error=/var/log/mysqld.log
pid-file=/var/run/mysqld/mysqld.pid