Skip to content

Instantly share code, notes, and snippets.

@globerunnerseo
Forked from thattommyhall/my.cnf
Created April 6, 2012 16:25
Show Gist options
  • Save globerunnerseo/2321117 to your computer and use it in GitHub Desktop.
Save globerunnerseo/2321117 to your computer and use it in GitHub Desktop.
Suggested my.cnf
[client]
default-character-set = utf8
socket = /tmp/mysql.sock
[mysqld]
#skip-grant-tables
max_sp_recursion_depth = 255
socket = /tmp/mysql.sock
tmpdir = /opt/tmp
default-collation = 'utf8_general_ci'
default-character-set = utf8
init-connect = 'SET NAMES utf8'
!include /etc/mysql
# Log slow queries
log-slow-queries = slow_queries.log
log-queries-not-using-indexes
log = /var/lib/mysql/mysqld.log
log-error = /var/lib/mysql/mysql.err
pid-file = /var/lib/mysql/fm-db-2.lon-mg.factorymedia.com.pid
# Added for performance reasons
query_cache_size = 1506M
key_buffer_size = 376M
table_open_cache = 2000
tmp_table_size = 6G
max_heap_table_size = 8032M
join_buffer_size = 376M
bulk_insert_buffer_size = 376M
innodb_buffer_pool_size = 8032M
innodb_flush_method=O_DIRECT
innodb_log_file_size = 1G
innodb_log_files_in_group = 2
myisam_sort_buffer_size = 1G
datadir = /var/lib/mysql
innodb_data_home_dir = /var/lib/mysql
innodb_file_per_table
innodb_table_locks = 0
innodb_open_files = 6000
# Changed by Mike/Fred 03 Feb 2009
lower_case_table_names = 1
# Added by Mike 30-01-2010 - XtraDB config
innodb_locks_unsafe_for_binlog=1
innodb_read_io_threads = 128
innodb_write_io_threads = 128
innodb_io_capacity = 999999999
innodb_flush_neighbor_pages = 1
innodb_show_verbose_locks = 1
innodb_show_locks_held = 1
# Added by Mike 17-05-2010 - PBXT config
pbxt_index_cache_size = 32M
pbxt_record_cache_size = 32M
pbxt_log_cache_size = 16M
pbxt_log_file_threshold = 128M
pbxt_transaction_buffer_size = 16M
pbxt_checkpoint_frequency = 24M
pbxt_sweeper_priority = 2
pbxt_auto_increment_mode = 1
#pbxt_flush_log_at_trx_commit = 0
pbxt_data_log_threshold = 256M
pbxt_garbage_threshold = 50
pbxt_log_buffer_size = 512M
pbxt_log_file_count = 6
pbxt_offline_log_function = 0
pbxt_data_file_grow_size = 10M
pbxt_row_file_grow_size = 1M
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment