Ii. MySQL configuration file template

Source: Internet
Author: User
Tags change settings

Cite the 8th chapter of high-performance MySQL

MY.CNF content:

# for advice The change settings
# http://dev.mysql.com/doc/refman/5.6/en/server-configuration-defaults.html

[Mysqld]
# Basedir = ...
# server_id = ...
DataDir =/var/lib/mysql
Port = 3306
Socket =/var/lib/mysql/mysql.sock
Pid_file =/var/lib/mysql/mysql.pid
user = MySQL
Default_storage_engine = InnoDB

# InnoDB
Innodb_buffer_pool_size = <value>

Innodb_log_file_size = <value>

innodb_file_per_table = 1
Innodb_flush_nethod = 0_direct

# MyISAM
Key_buffer_size = <value>

# log
# Log_bin
Log_error =/var/lib/mysql/mysql-error.log
Slow_query_log =/var/lib/mysql/mysql-slow.log

# Other
Tmp_table_size = 32M
Max_heap_table_size = 32M
Query_cache_type = 0
Query_cache_size = 0
Max_connections = <value>

Thread_cache = <value>

Table_cache = <value>

Open_files_limit = 65535

[Client]
Socket =/var/lib/mysql/mysql.sock
Port = 3306



# Remove Leading # To set options mainly useful for reporting servers.
# The server defaults is 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

Explicit_defaults_for_timestamp
#sql_mode =no_engine_substitution,strict_trans_tables

This article is from the "1058223494" blog, please be sure to keep this source http://4708705.blog.51cto.com/4698705/1585116

Ii. MySQL configuration file template

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.