Java321技术网
标题:
centos新安装mysql5.6报错了
[打印本页]
作者:
luozhangyou
时间:
2017-9-13 02:25
标题:
centos新安装mysql5.6报错了
2017-09-12 14:15:09 3442 [Note] Plugin 'FEDERATED' is disabled.
2017-09-12 14:15:09 3442 [Note] InnoDB: Using atomics to ref count buffer pool pages
2017-09-12 14:15:09 3442 [Note] InnoDB: The InnoDB memory heap is disabled
2017-09-12 14:15:09 3442 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
2017-09-12 14:15:09 3442 [Note] InnoDB: Memory barrier is not used
2017-09-12 14:15:09 3442 [Note] InnoDB: Compressed tables use zlib 1.2.3
2017-09-12 14:15:09 3442 [Note] InnoDB: Using Linux native AIO
2017-09-12 14:15:09 3442 [Note] InnoDB: Not using CPU crc32 instructions
2017-09-12 14:15:09 3442 [Note] InnoDB: Initializing buffer pool, size = 128.0M
InnoDB: mmap(136019968 bytes) failed; errno 12
2017-09-12 14:15:09 3442 [ERROR] InnoDB: Cannot allocate memory for the buffer pool
2017-09-12 14:15:09 3442 [ERROR] Plugin 'InnoDB' init function returned error.
2017-09-12 14:15:09 3442 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
2017-09-12 14:15:09 3442 [ERROR] Unknown/unsupported storage engine: InnoDB
2017-09-12 14:15:09 3442 [ERROR] Aborting
解决办法:
查看内存
$ free
total used free shared buffers cached
Mem: 608476 565044 43432 0 1284 53996
-/+ buffers/cache: 509764 98712
Swap: 0 0 0
复制代码
好吧,明显的swap问题。适当增加swap,采用
$ sudo dd if=/dev/zero of=/swapfile bs=1M count=1024 #增加1G的SWAP进去
$ sudo mkswap /swapfile
$ sudo swapon /swapfile
$ free
total used free shared buffers cached
Mem: 608476 601432 7044 0 824 88752
-/+ buffers/cache: 511856 96620
Swap: 1048572 0 1048572
复制代码
此处不建议将swapon 写到/etc/fstab这里,直接写到/etc.rc.local中更为稳妥
启动解决...
欢迎光临 Java321技术网 (https://java321.com/)
Powered by Discuz! X3.3