Более чем оптимальные конфиги MYSQL для разных серверов

1GB:

skip-external-locking
max_allowed_packet          = 16M
key_buffer_size             = 16M
innodb_buffer_pool_size     = 512M
innodb_file_per_table       = 1
innodb_flush_method         = O_DIRECT
innodb_flush_log_at_trx_commit  = 0
max_connections             = 132
query_cache_size            = 0
long_query_time             = 1
expire_logs_days            = 10
max_binlog_size             = 100M

2GB:

skip-external-locking
max_allowed_packet          = 16M
key_buffer_size             = 16M
innodb_buffer_pool_size     = 1024M
innodb_file_per_table       = 1
innodb_flush_method         = O_DIRECT
innodb_flush_log_at_trx_commit  = 0
max_connections             = 136
query_cache_size            = 0
long_query_time             = 1
expire_logs_days            = 10
max_binlog_size             = 100M

4GB:

skip-external-locking
max_allowed_packet          = 16M
key_buffer_size             = 16M
innodb_buffer_pool_size     = 2048M
innodb_file_per_table       = 1
innodb_flush_method         = O_DIRECT
innodb_flush_log_at_trx_commit  = 0
max_connections             = 144
query_cache_size            = 0
long_query_time             = 1
expire_logs_days            = 10
max_binlog_size             = 100M

8GB:

skip-external-locking
max_allowed_packet          = 16M
key_buffer_size             = 16M
innodb_buffer_pool_size     = 4096M
innodb_file_per_table       = 1
innodb_flush_method         = O_DIRECT
innodb_flush_log_at_trx_commit  = 0
max_connections             = 160
      query_cache_size            = 0
long_query_time             = 1
expire_logs_days            = 10
max_binlog_size             = 100M

16GB:

skip-external-locking
max_allowed_packet          = 16M
key_buffer_size             = 16M
innodb_buffer_pool_size     = 8192M
innodb_file_per_table       = 1
innodb_flush_method         = O_DIRECT
innodb_flush_log_at_trx_commit  = 0
max_connections             = 192
query_cache_size            = 0
long_query_time             = 1
expire_logs_days            = 10
max_binlog_size             = 100M

Так же не забывать удалять старые буферы в /var/lib/mysql/ после правки конфигов. 

2 комментария

  1. Very rapidly this web page will be famous among all blogging
    and site-building visitors, due to it’s good content

Оставьте ответ