因此,我正在尝试建立一个Drupal 7 my.conf文件,它将各种性能博客的最佳实践结合在一起。不过,我意识到,其中一些人比其他人更老,而且许多人并不是在使用InnoDB。因此,这一系列的吐露,如果你是为InnoDB而建的话,这是不相关的。
[client]
port = 3306
socket = /var/run/mysqld/mysqld.sock
[mysqld_safe]
socket = /var/run/mysqld/mysqld.sock
nice = 0
open-files-limit = 4096
[mysqld]
port = 3306
user = mysql
default_storage_engine
default-storage-engine = InnoDB
socket = /var/run/mysqld/mysqld.sock
pid_file = /var/run/mysqld/mysqld.pid
basedir = /usr
tmpdir = /tmp
lc-messages-dir = /usr/share/mysql
local-infile = 0
automatic_sp_privileges = 0
safe-user-create = 1
secure-auth = 1
secure-file-priv = /tmp
symbolic-links = 0
key_buffer_size = 32M
myisam-recover = BACKUP,FORCE
concurrent_insert = 2
max_allowed_packet = 16M
max_connect_errors = 1000000
datadir = /var/lib/mysql
tmp_table_size = 64M
max_heap_table_size = 64M
query_cache_type = 1
query_cache_size = 0
query_cache_limit = 8M
query_cache_min_res_unit = 1K
default-storage-engine = InnoDB
thread_stack = 256K
thread_cache_size = 128
max_connections = 128
open_files_limit = 65535
skip-locking
skip-bdb
server-id = 1
log_bin = /var/log/mysql/mysql-bin.log
binlog_cache_size = 256K
sync_binlog = 256
expire_logs_days = 14
max_binlog_size = 1G
binlog_do_db = include_database_name
binlog_ignore_db = include_database_name
max_user_connections = 150
key_buffer = 16M
key_cache_block_size = 4K
bulk_insert_buffer_size = 8M
innodb_buffer_pool_size = 6G
myisam_sort_buffer_size = 64M
join_buffer_size = 8M
read_buffer_size = 2M
sort_buffer_size = 3M
read_rnd_buffer_size = 64M
table_cache = 4096
table_definition_cache = 4096
table_open_cache = 16384
optimizer_search_depth = 4
collation-server = utf8_general_ci
interactive_timeout = 400
wait_timeout = 300
connect_timeout = 10
thread_concurrency=8
back_log = 2048
open-files = 10000
query_prealloc_size = 65536
query_alloc_block_size = 131072发布于 2013-03-28 17:46:13
请删除或更改以下内容:
skip-locking
skip-bdb
binlog_do_db = include_database_name
binlog_ignore_db = include_database_name
default_storage_engine
default_storage_engine = InnoDB
thread_concurrency=8
sync_binlog=256
bulk_insert_buffer_size = 8M原因如下:
my.cnf中LOAD DATA INFILE大容量加载行或从mysqldumps加载重分组行。基于Drupal 7使用InnoDB,所以我需要其他的信任吗?中的信息,有太多要添加的内容
https://dba.stackexchange.com/questions/38787
复制相似问题