我现在得到一些mysql错误。我的数字海洋5 $ plan.1 cpu,512 mb ram,centos 6.5,apache,mysql,nginx,cpanel。只有2个wordpress网站。
这是my.cnf
[mysqld]
port = 3306
socket = /var/lib/mysql/mysql.sock
default-storage-engine= MyISAM
max_connections = 150
key_buffer = 16K
max_allowed_packet = 1M
table_open_cache = 2000
sort_buffer_size = 64K
read_buffer_size = 256K
read_rnd_buffer_size = 256K
net_buffer_length = 2K
thread_stack = 64K
log-slow-queries= /var/lib/mysql/slow.log
log-error = /var/lib/mysql/error.log
thread_cache_size = 4
query_cache_type = 1
query_cache_size = 16M
query_cache_limit = 4M
# For low memory, InnoDB should not be used so keep skip-innodb uncommented unless required
skip-innodb
# Uncomment the following if you are using InnoDB tables
#innodb_data_home_dir = /var/lib/mysql/
#innodb_data_file_path = ibdata1:10M:autoextend
#innodb_log_group_home_dir = /var/lib/mysql/
#innodb_log_arch_dir = /var/lib/mysql/
# You can set .._buffer_pool_size up to 50 - 80 %
# of RAM but beware of setting memory usage too high
#innodb_buffer_pool_size = 16M
#innodb_additional_mem_pool_size = 2M
# Set .._log_file_size to 25 % of buffer pool size
#innodb_log_file_size = 5M
#innodb_log_buffer_size = 8M
#innodb_flush_log_at_trx_commit = 1
#innodb_lock_wait_timeout = 50
[mysqldump]
quick
max_allowed_packet = 16M
[mysql]
no-auto-rehash
# Remove the next comment character if you are not familiar with SQL
#safe-updates
[isamchk]
key_buffer = 8M
sort_buffer_size = 8M
[myisamchk]
key_buffer = 8M
sort_buffer_size = 8M
[mysqlhotcopy]
interactive-timeout
这是mysqltuner输出:http://i.imgur.com/DpDs2UK.png
上次mysql错误日志:
140818 14:01:15 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql
140818 14:01:15 [Warning] Using unique option prefix key_buffer instead of key_buffer_size is deprecated and will be removed in a future release. Please use the full name instead.
140818 14:01:15 [Warning] option 'thread_stack': unsigned value 65536 adjusted to 131072
140818 14:01:15 [Warning] The syntax '--log-slow-queries' is deprecated and will be removed in a future release. Please use '--slow-query-log'/'--slow-query-log-file' instead.
140818 14:01:15 [Note] Plugin 'FEDERATED' is disabled.
140818 14:01:15 [Note] Plugin 'InnoDB' is disabled.
140818 14:01:15 [Note] Server hostname (bind-address): '0.0.0.0'; port: 3306
140818 14:01:15 [Note] - '0.0.0.0' resolves to '0.0.0.0';
140818 14:01:15 [Note] Server socket created on IP: '0.0.0.0'.
140818 14:01:15 [Note] Event Scheduler: Loaded 0 events
140818 14:01:15 [Note] /usr/sbin/mysqld: ready for connections.
Version: '5.5.37-cll' socket: '/var/lib/mysql/mysql.sock' port: 3306 MySQL Community Server (GPL)
你能帮我解决吗,my.cnf文件.Mysql不断关闭自己。我正在使用Innodb.Here是我的sql日志关机错误:
140818 13:13:31 InnoDB: Initializing buffer pool, size = 16.0M
InnoDB: mmap(17170432 bytes) failed; errno 12
140818 13:13:31 InnoDB: Completed initialization of buffer pool
140818 13:13:31 InnoDB: Fatal error: cannot allocate memory for the buffer pool
140818 13:13:31 [ERROR] Plugin 'InnoDB' init function returned error.
140818 13:13:31 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
140818 13:13:31 [ERROR] Unknown/unsupported storage engine: InnoDB
140818 13:13:31 [ERROR] Aborting
140818 13:13:31 [Note] /usr/sbin/mysqld: Shutdown complete