Advertisement
Guest User

my.cnf

a guest
Oct 4th, 2018
106
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. # GENERAL datadir
  2. [mysqld]
  3. basedir                                                     = /usr
  4. datadir                                                     = /var/lib/mysql
  5. tmpdir                                                      = /tmp
  6. user                                                        = mysql
  7. socket                                                      = /var/run/mysqld/mysqld.sock
  8. pid-file                                                    = /var/run/mysqld/mysqld.pid
  9. log_error                                                   = /var/log/mysql/error.log
  10. general_log_file                                            = /var/log/mysql/mysql.log
  11. lc-messages-dir                                             = /usr/share/mysql
  12. slow_query_log                                              = 1
  13. long_query_time                                             = 1
  14. open_files_limit                                            = 4000
  15. innodb_open_files                                           = 4000
  16.  
  17. # INNODB
  18. default_storage_engine                                      = InnoDB
  19. innodb_buffer_pool_size                                     = 32768M
  20. innodb_log_buffer_size                                      = 128M
  21. innodb_log_file_size                                        = 2048M
  22. innodb_buffer_pool_instances                                = 8
  23. innodb_flush_method                                         = O_DIRECT
  24. innodb_flush_log_at_trx_commit                              = 0
  25. innodb_autoinc_lock_mode                                    = 0
  26. innodb_file_per_table                                       = 1
  27. max_connections                                             = 512
  28. max_allowed_packet                                          = 512M
  29. max_connect_errors                                          = 1024
  30. table_open_cache                                            = 4000
  31. query_cache_type                                            = 0
  32. thread_cache_size                                           = 128
  33. thread_stack                                                = 512K
  34. innodb_thread_concurrency                                   = 0
  35. query_cache_size                                            = 0
  36. userstat                                                    = On
  37. performance_schema                                          = On
  38. #query_response_time_stats                                  = On
  39. performance_schema_digests_size                             = 200
  40. performance_schema_events_waits_history_size                = 20
  41. performance_schema_events_waits_history_long_size           = 15000
  42. collation-server                                            = utf8mb4_general_ci
  43. character-set-server                                        = utf8mb4
  44. wait_timeout                                                = 600
  45. interactive_timeout                                         = 600
  46. #***
  47. innodb_support_xa                                           = 0
  48. sync_binlog                                                 = 0
  49. transaction-isolation                                       = READ-COMMITTED
  50. innodb_locks_unsafe_for_binlog                              = 1
  51. innodb_doublewrite                                          = 0
  52. innodb_io_capacity                                          = 600
  53. innodb_read_io_threads                                      = 4
  54. innodb_write_io_threads                                     = 4
  55. innodb_old_blocks_time                                      = 1000
  56. innodb_adaptive_hash_index                                  = 0
  57. innodb_purge_threads                                        = 4
  58. table_definition_cache                                      = 4000
  59.  
  60.  
  61. # OTHER
  62. [client]
  63. port                                                        = 3306
  64. socket                                                      = /var/run/mysqld/mysqld.sock
  65. default-character-set                                       = utf8mb4
  66. [mysqld_safe]
  67. socket                                                      = /var/run/mysqld/mysqld.sock
  68. nice                                                        = 0
  69. [mysqldump]
  70. quick
  71. quote-names
  72. max_allowed_packet                                          = 512M
  73. [isamchk]
  74. key_buffer                                                  = 512M
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement