#
# Generated by Chef for <%= node['hostname'] %>
#
# Local modifications will be overwritten.
#
# The MySQL database server configuration file.
#
# One can use all long options that the program supports.
# Run program with --help to get a list of available options and with
# --print-defaults to see which it would actually understand and use.
#
# For explanations see
# http://dev.mysql.com/doc/mysql/en/server-system-variables.html

# This will be passed to all mysql clients
# It has been reported that passwords should be enclosed with ticks/quotes
# escpecially if they contain "#" chars...
[client]
port = 3306

[mysql]
default-character-set = latin1

[mysqld]
#
# * Basic Settings
#
port                      = 3306
basedir                   = <%= node['mysql']['basedir'] %>
datadir                   = <%= node['mysql']['data_dir'] %>
character-set-server      = latin1
default-storage-engine    = INNODB
sql-mode                  = "STRICT_TRANS_TABLES,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION"

#
# * Fine Tuning
#
thread_cache_size         = <%= node['mysql']['tunable']['thread_cache_size'] %>
max_connections           = <%= node['mysql']['tunable']['max_connections'] %>
table_cache               = <%= node['mysql']['tunable']['table_cache'] %>
query_cache_size          = <%= node['mysql']['tunable']['query_cache_size'] %>
tmp_table_size            = 5M
myisam_max_sort_file_size = 100G
myisam_sort_buffer_size   = 8M
key_buffer_size           = 8M
read_buffer_size          = 64K
read_rnd_buffer_size      = 256K
sort_buffer_size          = 212K

#
# * InnoDB
#
# Read the manual for more InnoDB related options. There are many!
# You might want to disable InnoDB to shrink the mysqld process by circa 100MB.
#
innodb_additional_mem_pool_size = 2M
innodb_flush_log_at_trx_commit  = 1
innodb_log_buffer_size          = 1M
innodb_buffer_pool_size         = <%= node['mysql']['tunable']['innodb_buffer_pool_size'] %>
innodb_log_file_size            = 10M
innodb_thread_concurrency       = 8
