tuning mysqla

/etc/mysql/my.cnf

link

Koniecznie pod tagiem [mysqld] !!!!

 

#
# The MySQL database server configuration file.
#
# You can copy this to one of:
# - "/etc/mysql/my.cnf" to set global options,
# - "~/.my.cnf" to set user-specific options.
# 
# 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...
# Remember to edit /etc/mysql/debian.cnf when changing the socket location.

# Here is entries for some specific programs
# The following values assume you have at least 32M ram

!includedir /etc/mysql/conf.d/


[mysqld]
max_connections = 500

max_allowed_packet=768M
key_buffer_size=2048M //dla mysam !!! malo wazne

innodb_buffer_pool_size=512M
innodb_log_file_size=128M
innodb_log_buffer_size=512M

query_cache_limit		= 0M
query_cache_size		= 0M

innodb_buffer_pool_instances=2

#tmp_table_size=2G
#max_heap_table_size=2G
Komentarze wyłączone