我一直在运行这个WordPress站点很长一段时间没有问题,但最近一直在收到错误“建立数据库连接时出错”。如果我重新启动MySQL,问题暂时得到解决,但很快就会回来。建立数据库连接的Wordpress错误 - 内存问题
查看MySQL日志文件后,我认为问题是由于某种内存泄漏,但我无法追查问题的根源。
total used free shared buffers cached
Mem: 987 968 18 26 18 137
-/+ buffers/cache: 812 175
Swap: 255 35 220
这将是真棒,如果有人可以帮助我使这篇日志的意义:
我已阅读,问题可能来自未配置交换文件是未来,但是我已经配置如下交换文件。
MySQL的日志文件:
2016-03-17 06:48:45 3575 [Warning] Using unique option prefix myisam-recover instead of myisam-recover-options is deprecated and will be removed in a future release. Please use the full name instead.
2016-03-17 06:48:45 3575 [Note] Plugin 'FEDERATED' is disabled.
2016-03-17 06:48:45 3575 [ERROR] Function 'innodb' already exists
2016-03-17 06:48:45 3575 [Warning] Couldn't load plugin named 'innodb' with soname 'ha_innodb.so'.
2016-03-17 06:48:45 3575 [ERROR] Function 'federated' already exists
2016-03-17 06:48:45 3575 [Warning] Couldn't load plugin named 'federated' with soname 'ha_federated.so'.
2016-03-17 06:48:45 3575 [ERROR] Function 'blackhole' already exists
2016-03-17 06:48:45 3575 [Warning] Couldn't load plugin named 'blackhole' with soname 'ha_blackhole.so'.
2016-03-17 06:48:45 3575 [ERROR] Function 'archive' already exists
2016-03-17 06:48:45 3575 [Warning] Couldn't load plugin named 'archive' with soname 'ha_archive.so'.
2016-03-17 06:48:45 3575 [Note] InnoDB: Using atomics to ref count buffer pool pages
2016-03-17 06:48:45 3575 [Note] InnoDB: The InnoDB memory heap is disabled
2016-03-17 06:48:45 3575 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
2016-03-17 06:48:45 3575 [Note] InnoDB: Memory barrier is not used
2016-03-17 06:48:45 3575 [Note] InnoDB: Compressed tables use zlib 1.2.8
2016-03-17 06:48:45 3575 [Note] InnoDB: Using Linux native AIO
2016-03-17 06:48:45 3575 [Note] InnoDB: Using CPU crc32 instructions
2016-03-17 06:48:45 3575 [Note] InnoDB: Initializing buffer pool, size = 128.0M
InnoDB: mmap(137363456 bytes) failed; errno 12
2016-03-17 06:48:45 3575 [ERROR] InnoDB: Cannot allocate memory for the buffer pool
2016-03-17 06:48:45 3575 [ERROR] Plugin 'InnoDB' init function returned error.
2016-03-17 06:48:45 3575 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
2016-03-17 06:48:45 3575 [ERROR] Unknown/unsupported storage engine: InnoDB
2016-03-17 06:48:45 3575 [ERROR] Aborting
2016-03-17 06:48:45 3575 [Note] Binlog end
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'partition'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'BLACKHOLE'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'ARCHIVE'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'PERFORMANCE_SCHEMA'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'INNODB_SYS_DATAFILES'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'INNODB_SYS_TABLESPACES'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'INNODB_SYS_FOREIGN_COLS'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'INNODB_SYS_FOREIGN'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'INNODB_SYS_FIELDS'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'INNODB_SYS_COLUMNS'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'INNODB_SYS_INDEXES'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'INNODB_SYS_TABLESTATS'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'INNODB_SYS_TABLES'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'INNODB_FT_INDEX_TABLE'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'INNODB_FT_INDEX_CACHE'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'INNODB_FT_CONFIG'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'INNODB_FT_BEING_DELETED'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'INNODB_FT_DELETED'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'INNODB_FT_DEFAULT_STOPWORD'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'INNODB_METRICS'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'INNODB_BUFFER_POOL_STATS'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'INNODB_BUFFER_PAGE_LRU'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'INNODB_BUFFER_PAGE'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'INNODB_CMP_PER_INDEX_RESET'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'INNODB_CMP_PER_INDEX'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'INNODB_CMPMEM_RESET'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'INNODB_CMPMEM'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'INNODB_CMP_RESET'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'INNODB_CMP'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'INNODB_LOCK_WAITS'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'INNODB_LOCKS'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'INNODB_TRX'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'CSV'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'MEMORY'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'MRG_MYISAM'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'MyISAM'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'sha256_password'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'mysql_old_password'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'mysql_native_password'
2016-03-17 06:48:45 3575 [Note] Shutting down plugin 'binlog'
2016-03-17 06:48:45 3575 [Note] /usr/sbin/mysqld: Shutdown complete
2016-03-17 06:48:46 3606 [Warning] Using unique option prefix myisam-recover instead of myisam-recover-options is deprecated and will be removed in a future release. Please use the full name instead.
2016-03-17 06:48:46 3606 [Note] Plugin 'FEDERATED' is disabled.
2016-03-17 06:48:46 3606 [ERROR] Function 'innodb' already exists
2016-03-17 06:48:46 3606 [Warning] Couldn't load plugin named 'innodb' with soname 'ha_innodb.so'.
2016-03-17 06:48:46 3606 [ERROR] Function 'federated' already exists
2016-03-17 06:48:46 3606 [Warning] Couldn't load plugin named 'federated' with soname 'ha_federated.so'.
2016-03-17 06:48:46 3606 [ERROR] Function 'blackhole' already exists
2016-03-17 06:48:46 3606 [Warning] Couldn't load plugin named 'blackhole' with soname 'ha_blackhole.so'.
2016-03-17 06:48:46 3606 [ERROR] Function 'archive' already exists
2016-03-17 06:48:46 3606 [Warning] Couldn't load plugin named 'archive' with soname 'ha_archive.so'.
2016-03-17 06:48:46 3606 [Note] InnoDB: Using atomics to ref count buffer pool pages
2016-03-17 06:48:46 3606 [Note] InnoDB: The InnoDB memory heap is disabled
2016-03-17 06:48:46 3606 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
2016-03-17 06:48:46 3606 [Note] InnoDB: Memory barrier is not used
2016-03-17 06:48:46 3606 [Note] InnoDB: Compressed tables use zlib 1.2.8
2016-03-17 06:48:46 3606 [Note] InnoDB: Using Linux native AIO
2016-03-17 06:48:46 3606 [Note] InnoDB: Using CPU crc32 instructions
2016-03-17 06:48:46 3606 [Note] InnoDB: Initializing buffer pool, size = 128.0M
InnoDB: mmap(137363456 bytes) failed; errno 12
2016-03-17 06:48:46 3606 [ERROR] InnoDB: Cannot allocate memory for the buffer pool
2016-03-17 06:48:46 3606 [ERROR] Plugin 'InnoDB' init function returned error.
2016-03-17 06:48:46 3606 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
2016-03-17 06:48:46 3606 [ERROR] Unknown/unsupported storage engine: InnoDB
2016-03-17 06:48:46 3606 [ERROR] Aborting
可以粘贴一些之前会发生什么2016-03-17 06:48:46 3606? – obe
@obe是否添加了您要查找的部分? – Tony