双mysql之配置文件my.cnf
双mysql之配置文件my.cnf
钱宏健 发表于10个月前
双mysql之配置文件my.cnf
  • 发表于 10个月前
  • 阅读 1
  • 收藏 0
  • 点赞 0
  • 评论 0

移动开发云端新模式探索实践 >>>   

# For advice on how to change settings please see
# http://dev.mysql.com/doc/refman/5.6/en/server-configuration-defaults.html
# *** DO NOT EDIT THIS FILE. It's a template which will be copied to the
# *** default location during install, and will be replaced if you
# *** upgrade to a newer version of MySQL.
[client]
port = 3307
#default-character-set = utf8
default-character-set = utf8mb4




[mysqld]


# Remove leading # and set to the amount of RAM for the most important data
# cache in MySQL. Start at 70% of total RAM for dedicated server, else 10%.
# innodb_buffer_pool_size = 128M


# Remove leading # to turn on a very important data integrity option: logging
# changes to the binary log between backups.
# log_bin


# These are commonly set, remove the # and set as required.
port = 3307
user = mysql1 
basedir = /usr/local/mysql1
datadir = /home/data/mysql1/data
wait_timeout = 31536000
max_connections = 1000
max_user_connections = 1000
max_connect_errors=1000
character_set_server=utf8
#character-set-server = utf8mb4
#character-set_connection = utf8mb4
#character-set_database = utf8mb4
#character_set_results = utf8mb4
#collation-server = utf8mb4_unicode_ci
character-set-client-handshake = FALSE
character-set-server = utf8mb4
collation-server = utf8mb4_unicode_ci
init_connect='SET NAMES utf8mb4'


skip-external-locking
key_buffer_size = 128M
max_allowed_packet = 5M
table_open_cache = 512
sort_buffer_size = 2M
read_buffer_size = 2M
read_rnd_buffer_size = 8M
myisam_sort_buffer_size = 64M
thread_cache_size = 8
query_cache_type = 1
query_cache_size = 32M
# port = .....
# server_id = .....
 socket = /tmp/mysql1.sock
log-error = /home/data/logs/mysql1/mysql1_error.log
pid-file = /home/data/mysql1/data/mysql1.pid


# Remove leading # to set options mainly useful for reporting servers.
# The server defaults are faster for transactions and fast SELECTs.
# Adjust sizes as needed, experiment to find the optimal values.
# join_buffer_size = 128M
# sort_buffer_size = 2M
# read_rnd_buffer_size = 2M 


sql_mode=NO_ENGINE_SUBSTITUTION,STRICT_TRANS_TABLES 




[mysql]
no-auto-rehash
default-character-set = utf8mb4


[myisamchk]
key_buffer_size = 256K
sort_buffer_size = 256K
read_buffer = 256K
write_buffer = 256K




[mysqlhotcopy]
interactive-timeout
  • 打赏
  • 点赞
  • 收藏
  • 分享
共有 人打赏支持
粉丝 0
博文 6
码字总数 11459
×
钱宏健
如果觉得我的文章对您有用,请随意打赏。您的支持将鼓励我继续创作!
* 金额(元)
¥1 ¥5 ¥10 ¥20 其他金额
打赏人
留言
* 支付类型
微信扫码支付
打赏金额:
已支付成功
打赏金额: