最近跑博客的小机总出现 Mysql 挂掉的情况
日志如下:
2020-03-29T12:47:50.856945Z 0 [Note] InnoDB: Initializing buffer pool, total size = 128M, instances = 1, chunk size = 128M
2020-03-29T12:47:50.942730Z 0 [ERROR] InnoDB: mmap(139722752 bytes) failed; errno 12
2020-03-29T12:47:50.942773Z 0 [ERROR] InnoDB: Cannot allocate memory for the buffer pool
2020-03-29T12:47:50.942783Z 0 [ERROR] InnoDB: Plugin initialization aborted with error Generic error
2020-03-29T12:47:50.942797Z 0 [ERROR] Plugin 'InnoDB' init function returned error.
2020-03-29T12:47:50.942803Z 0 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
2020-03-29T12:47:50.942811Z 0 [ERROR] Failed to initialize builtin plugins.
2020-03-29T12:47:50.942816Z 0 [ERROR] Aborting
查看内存,发现内存2G 应该是足够用的。再看 Swap,`total`为0
[root@4wei_cn log]# free -m
total u