SharkIng 发表于 2015-12-20 08:34:26

MySQL 无法启动,在哪里看日志呢?

提示:The server quit without updating PID file (/var/run/mysqld/mysqld.pid).
查看了硬盘空间,确定没有满

尝试查看了/usr/local/mysql/var/localhost.pid 不存在 (原先用的,Stop之后就没有了)
尝试查看了 /usr/local/mysql/var/localhost.err 没有什么特别的错误

最后的提示是

1512208:22:49 /usr/local/mysql/bin/mysqld: Normal shutdown

1512208:22:49 Event Scheduler: Purging the queue. 0 events
1512208:22:49InnoDB: Starting shutdown...
1512208:22:50InnoDB: Shutdown completed; log sequence number 8326197738
1512208:22:50 /usr/local/mysql/bin/mysqld: Shutdown complete

151220 08:22:50 mysqld_safe mysqld from pid file /usr/local/mysql/var/localhost.pid ended


是我stop mysql的提示

查看了权限 /usr/local/mysql/var 是 mysql:mysql 权限,其他的是 root:mysql权限,然后/var/run/mysql 是 root:mysql权限 (所有权限都是原来安装时候弄好的,从来没改过,以前都好好的,什么都没改过)

所以现在怎么排除错误呢??

licess 发表于 2015-12-20 09:45:48

置顶帖反馈必读有具体说明

SharkIng 发表于 2015-12-20 09:49:07

原帖由 licess 于 2015-12-20 09:45 发表 https://bbs.vpser.net/images/common/back.gif
置顶帖反馈必读有具体说明
感谢军哥回复那么块,我看了说明,但是在.err 那个文件中什么有用信息都没有,我在原帖中贴出的就是最新的信息,不管我怎么用 sudo lnmp mysql start 启动,怎么提示 PID的问题,都无法在.err中记录任何信息。

求解为什么?

SharkIng 发表于 2015-12-20 09:55:12

151215 12:27:00 IP address '45.34.34.179' could not be resolved: Temporary failure in name resolution
151215 12:27:01 IP address '45.34.34.179' could not be resolved: Temporary failure in name resolution
151215 12:27:01 IP address '45.34.34.179' could not be resolved: Temporary failure in name resolution
151215 12:27:01 IP address '45.34.34.179' could not be resolved: Temporary failure in name resolution
151215 12:27:02 IP address '45.34.34.179' could not be resolved: Temporary failure in name resolution
151215 12:27:02 IP address '45.34.34.179' could not be resolved: Temporary failure in name resolution
151215 12:27:03 IP address '45.34.34.179' could not be resolved: Temporary failure in name resolution
151215 12:27:03 IP address '45.34.34.179' could not be resolved: Temporary failure in name resolution
151215 19:16:49 IP address '180.97.215.2' could not be resolved: Name or service not known
151215 19:16:49 IP address '180.97.215.2' could not be resolved: Name or service not known
1512170:56:40 IP address '103.241.51.11' could not be resolved: Name or service not known
151217 11:39:20 IP address '183.60.227.9' could not be resolved: Name or service not known
151217 16:24:37 IP address '124.232.150.230' could not be resolved: Name or service not known
151217 20:59:20 IP address '27.255.67.132' could not be resolved: Name or service not known
1512181:38:32 IP address '182.254.149.138' could not be resolved: Name or service not known
1512184:04:23 IP address '185.35.62.11' could not be resolved: Name or service not known
1512188:36:16 IP address '150.242.249.86' could not be resolved: Name or service not known
151218 11:18:37 IP address '222.186.134.55' could not be resolved: Name or service not known
151219 21:53:59 IP address '222.186.31.151' could not be resolved: Name or service not known
151219 22:43:10 IP address '222.186.30.247' could not be resolved: Name or service not known
1512204:53:53 IP address '222.186.51.141' could not be resolved: Name or service not known
1512208:22:49 /usr/local/mysql/bin/mysqld: Normal shutdown

1512208:22:49 Event Scheduler: Purging the queue. 0 events
1512208:22:49InnoDB: Starting shutdown...
1512208:22:50InnoDB: Shutdown completed; log sequence number 8326197738
1512208:22:50 /usr/local/mysql/bin/mysqld: Shutdown complete

151220 08:22:50 mysqld_safe mysqld from pid file /usr/local/mysql/var/localhost.com.pid ended
➜ SharkIng@localhost.com/usr/local/mysql/var>cat localhost.com.err

这里就是从15号至今(刚刚看得)的.err里面的文件,现在mysql处于没有run的状态,运行 lnmp mysql start 提示

+-------------------------------------------+
|    Manager for LNMP, Written by Licess    |
+-------------------------------------------+
|            http://lnmp.org            |
+-------------------------------------------+
Starting MySQL
. * The server quit without updating PID file (/var/run/mysqld/mysqld.pid).

mysql无法正常启动

SharkIng 发表于 2015-12-20 12:25:21

已解决,谢谢了

似乎是my.cnf上面的问题

先后顺序不知道为什么成了 /etc/mysql/my.cnf先 /etc/my.cnf后,所以改了 /etc/my.cnf后么有反映,cp到/etc/mysql/my.cnf之后就好了

licess 发表于 2015-12-20 12:26:59

有/var/run/mysql 这个目录就有点不正常了,检查一下是否有yum或apt-get安装的mysql 进行干扰

SharkIng 发表于 2015-12-21 05:14:45

原帖由 licess 于 2015-12-20 12:26 发表 https://bbs.vpser.net/images/common/back.gif
有/var/run/mysql 这个目录就有点不正常了,检查一下是否有yum或apt-get安装的mysql 进行干扰
前两天通过apt-get upgrade了一下所有安装程序后出现的问题,可能有关,修改/etc/mysql/my.cnf 之后就好了。

licess 发表于 2015-12-21 09:43:48

回复 7# 的帖子

有/etc/mysql/my.cnf 这个文件肯定是ap-get 安装上了另外的mysql
页: [1]
查看完整版本: MySQL 无法启动,在哪里看日志呢?