概述
mysql配置文件my.cnf
mysql配置文件如下:
[mysqld]
character-set-server=utf8mb4
#skip-grant-tables
log-bin=mysql-bin
binlog-format=ROW
binlog-ignore-db=mysql
server-id=1
user=mysql
port=3306
basedir=/var/log/mysql
datadir=/home/mysql_data
socket=/var/log/mysql/mysql.sock
sql_mode=STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION
log-error=/var/log/mysqld.log
pid-file=/var/run/mysqld/mysqld.pid
lower_case_table_names=1
transaction_isolation=READ-COMMITTED
max_connections=2000
max_connect_errors=2000
innodb_buffer_pool_size=12GB #70% RAM
innodb_file_per_table=1
innodb_log_file_size=500M
innodb_log_buffer_size=500M
innodb_flush_log_at_trx_commit=1
innodb_print_all_deadlocks=1
innodb_flush_method=O_DIRECT
innodb_read_io_threads=8
innodb_write_io_threads=8
innodb_io_capacity=5000
innodb_io_capacity_max=20000
innodb_lock_wait_timeout=20000
innodb_large_prefix=on
[mysqld_safe]
log-error=/var/log/mysqld.log
pid-file=/var/run/mysqld/mysqld.pid
最后
以上就是怕孤独荷花为你收集整理的mysql配置文件my.cnfmysql配置文件my.cnf的全部内容,希望文章能够帮你解决mysql配置文件my.cnfmysql配置文件my.cnf所遇到的程序开发问题。
如果觉得靠谱客网站的内容还不错,欢迎将靠谱客网站推荐给程序员好友。
本图文内容来源于网友提供,作为学习参考使用,或来自网络收集整理,版权属于原作者所有。
发表评论 取消回复