Skip to content

Instantly share code, notes, and snippets.

@griggheo
Created September 10, 2010 04:59
Show Gist options
  • Save griggheo/573125 to your computer and use it in GitHub Desktop.
Save griggheo/573125 to your computer and use it in GitHub Desktop.
[client]
port = 3306
socket = /var/lib/mysql/m0/mysqld.sock
# Here is entries for some specific programs
# The following values assume you have at least 32M ram
# This was formally known as [safe_mysqld]. Both versions are currently parsed.
[mysqld_safe]
socket = /var/lib/mysql/m0/mysqld.sock
nice = 0
[mysqld]
#
# * Basic Settings
#
user = mysql
pid-file = /var/lib/mysql/m0/mysqld.pid
socket = /var/lib/mysql/m0/mysqld.sock
port = 3306
basedir = /usr
datadir = /var/lib/mysql/m0
tmpdir = /tmp
language = /usr/share/mysql/english
skip-locking
key_buffer = 5G
max_allowed_packet = 16M
table_cache = 2048
sort_buffer_size = 8M
read_buffer_size = 2M
read_rnd_buffer_size = 8M
myisam_sort_buffer_size = 128M
bulk_insert_buffer_size = 64M
myisam_repair_thread = 2
myisam_max_sort_file_size = 10G
thread_cache_size = 64
query_cache_type = 1
query_cache_limit = 2M
query_cache_size = 32M
# Try number of CPU's*2 for thread_concurrency
thread_concurrency = 8
max_connections = 1000
max_connect_errors = 1000
join_buffer_size =8M
tmp_table_size = 64M
expire_logs_days = 1
ft_min_word_len = 3
# Disable Federated by default
#skip-federated
# Replication Master Server (default)
# binary logging is required for replication
server-id = 500
log_bin = /var/lib/mysql/m0/mysql-bin.log
expire_logs_days = 10
max_binlog_size = 100M
binlog_do_db = mydb
#binlog_ignore_db = mysql
binlog_ignore_db = test
# Master-master settings
auto_increment_increment=2
auto_increment_offset=1
#log-slave-updates
log_slow_queries = /var/lib/mysql/m0/mysql-slow.log
long_query_time = 0.500
#log-queries-not-using-indexes
# Uncomment the following if you are using InnoDB tables
innodb_data_home_dir = /var/lib/mysql/m0
innodb_data_file_path = ibdatafile:10G:autoextend
innodb_log_group_home_dir = /var/lib/mysql/m0
# You can set .._buffer_pool_size up to 50 - 80 %
# of RAM but beware of setting memory usage too high
#innodb_buffer_pool_size = 384M
#innodb_additional_mem_pool_size = 20M
# Set .._log_file_size to 25 % of buffer pool size
#innodb_log_file_size = 100M
#innodb_log_buffer_size = 8M
#innodb_flush_log_at_trx_commit = 1
#innodb_lock_wait_timeout = 50
innodb_buffer_pool_size = 4G
innodb_additional_mem_pool_size = 32M
#innodb_flush_method=O_DIRECT
innodb_log_file_size = 512M
#innodb_read_io_threads = 4
#innodb_write_io_threads = 4
innodb_file_per_table
innodb_flush_log_at_trx_commit=1
innodb_log_buffer_size = 8M
innodb_thread_concurrency=0
innodb_use_sys_malloc=1
#innodb_doublewrite = 0
[mysqldump]
quick
max_allowed_packet = 16M
[mysql]
no-auto-rehash
# Remove the next comment character if you are not familiar with SQL
#safe-updates
[isamchk]
key_buffer = 256M
sort_buffer_size = 256M
read_buffer = 2M
write_buffer = 2M
[myisamchk]
key_buffer = 256M
sort_buffer_size = 256M
read_buffer = 2M
write_buffer = 2M
[mysqlhotcopy]
interactive-timeout
#
# * IMPORTANT: Additional settings that can override those from this file!
# The files must end with '.cnf', otherwise they'll be ignored.
#
!includedir /etc/mysql0/conf.d/
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment