VPS侦探论坛

 找回密码
 注册
查看: 3102|回复: 5

Ubuntu LNMP mysql 不能開啟

[复制链接]
发表于 2017-7-16 11:29:58 | 显示全部楼层 |阅读模式

我在ubuntu 安裝LNMP 已經一年多,在今天網頁不能顯示(沒有做任何改動)
在後台重啟後出現mysql 已經 stop by time out

重新啟動也不成:
相關資料如下
應該怎樣解決?

mysql.service - LSB: start and stop MySQL
   Loaded: loaded (/etc/init.d/mysql; bad; vendor preset: enabled)
  Drop-In: /etc/systemd/system/mysql.service.d
           └─override.conf
   Active: failed (Result: timeout) since Sun 2017-07-16 11:24:25 CST; 4min 41s ago
     Docs: man:systemd-sysv-generator(8)
  Process: 6345 ExecStart=/etc/init.d/mysql start (code=killed, signal=TERM)
   CGroup: /system.slice/mysql.service
           ├─6357 /bin/sh /usr/local/mysql/bin/mysqld_safe --datadir=/usr/local/mysql/var --pid-fi...
           └─6860 /usr/local/mysql/bin/mysqld --basedir=/usr/local/mysql --datadir=/usr/local/mysq...

Jul 16 11:24:24 mcpa2015 systemd[1]: Starting LSB: start and stop MySQL...
Jul 16 11:24:24 mcpa2015 mysql[6345]: Starting MySQL
Jul 16 11:24:25 mcpa2015 systemd[1]: mysql.service: Start operation timed out. Terminating.
Jul 16 11:24:25 mcpa2015 systemd[1]: Failed to start LSB: start and stop MySQL.
Jul 16 11:24:25 mcpa2015 systemd[1]: mysql.service: Unit entered failed state.
Jul 16 11:24:25 mcpa2015 systemd[1]: mysql.service: Failed with result 'timeout'.
美国VPS推荐: 遨游主机LinodeLOCVPS主机云搬瓦工80VPSVultr美国VPS主机中国VPS推荐: 阿里云腾讯云。LNMP付费服务(代装/问题排查)QQ 503228080
发表于 2017-7-16 18:18:16 | 显示全部楼层


按反馈必读提供mysql日志
Linux下Nginx+MySQL+PHP自动安装工具:https://lnmp.org
 楼主| 发表于 2017-7-16 19:22:07 | 显示全部楼层

上傳.err 檔案
感謝幫助

本帖子中包含更多资源

您需要 登录 才可以下载或查看,没有账号?注册

x
美国VPS推荐: 遨游主机LinodeLOCVPS主机云搬瓦工80VPSVultr美国VPS主机中国VPS推荐: 阿里云腾讯云。LNMP付费服务(代装/问题排查)QQ 503228080
发表于 2017-7-17 11:22:21 | 显示全部楼层

回复 3# 的帖子




2017-07-16T03:32:09.303057Z 0 [ERROR] Can't create thread to handle new connection(errno= 11)
2017-07-16T03:32:09.310581Z 320 [Note] Aborted connection 320 to db: 'mcpa' user: 'mcpa' host: 'localhost' (Got an error reading communication packets)
Killed
。。。。。
2017-07-16T03:32:12.038928Z 0 [ERROR] InnoDB: mmap(137428992 bytes) failed; errno 12
2017-07-16T03:32:12.038975Z 0 [ERROR] InnoDB: Cannot allocate memory for the buffer pool
2017-07-16T03:32:12.038986Z 0 [ERROR] InnoDB: Plugin initialization aborted with error Generic error
2017-07-16T03:32:12.039021Z 0 [ERROR] Plugin 'InnoDB' init function returned error.
2017-07-16T03:32:12.039031Z 0 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
2017-07-16T03:32:12.039044Z 0 [ERROR] Failed to initialize plugins.
2017-07-16T03:32:12.039050Z 0 [ERROR] Aborting

内存不足mysql被kill,再启动时内存也不够分配的,如果不太以来innodb引擎可以调整 innodb_buffer_pool_size 调小些
Linux下Nginx+MySQL+PHP自动安装工具:https://lnmp.org
 楼主| 发表于 2017-7-17 21:52:50 | 显示全部楼层

但內存有4G,可用超過2G的容量也會這樣?

军哥运维代购:http://shop63846532.taobao.com/

 楼主| 发表于 2017-7-17 22:00:11 | 显示全部楼层

調小 innodb_buffer_pool_size 後 LNMP restart 後 可以了
您需要登录后才可以回帖 登录 | 注册

本版积分规则

小黑屋|手机版|Archiver|VPS侦探 ( 鲁ICP备16040043号-1 )

GMT+8, 2024-11-18 00:33 , Processed in 0.029954 second(s), 17 queries .

Powered by Discuz! X3.4

© 2001-2023 Discuz! Team.

快速回复 返回顶部 返回列表