fengjinyuan 发表于 2015-11-12 13:55:21

mysql 开启不了

Linux pub-PowerEdge-R820 3.19.0-25-generic #26~14.04.1-Ubuntu SMP Fri Jul 24 21:16:20 UTC 2015 x86_64
Linux内核版本:3.19.0-25-generic

151112 09:54:02 mysqld_safe Starting mysqld daemon with databases from /usr/local/mysql/var
1511129:54:02 Fatal error: Can't change to run as user 'mysql' ;Please check that the user exists!

1511129:54:02 Aborting

1511129:54:02 /usr/local/mysql/libexec/mysqld: Shutdown complete

151112 09:54:02 mysqld_safe mysqld from pid file /usr/local/mysql/var/pub-PowerEdge-R820.pid ended
151112 09:54:03 mysqld_safe Starting mysqld daemon with databases from /usr/local/mysql/var
1511129:54:03 Fatal error: Can't change to run as user 'mysql' ;Please check that the user exists!

1511129:54:03 Aborting

1511129:54:03 /usr/local/mysql/libexec/mysqld: Shutdown complete

151112 09:54:03 mysqld_safe mysqld from pid file /usr/local/mysql/var/pub-PowerEdge-R820.pid ended
151112 10:07:00 mysqld_safe Starting mysqld daemon with databases from /usr/local/mysql/var
151112 10:07:00 Fatal error: Can't change to run as user 'mysql' ;Please check that the user exists!

151112 10:07:00 Aborting

151112 10:07:00 /usr/local/mysql/libexec/mysqld: Shutdown complete

151112 10:07:00 mysqld_safe mysqld from pid file /usr/local/mysql/var/pub-PowerEdge-R820.pid ended
151112 10:59:40 mysqld_safe Starting mysqld daemon with databases from /usr/local/mysql/var
151112 10:59:40 Fatal error: Can't change to run as user 'mysql' ;Please check that the user exists!

151112 10:59:40 Aborting

151112 10:59:40 /usr/local/mysql/libexec/mysqld: Shutdown complete

151112 10:59:40 mysqld_safe mysqld from pid file /usr/local/mysql/var/pub-PowerEdge-R820.pid ended
151112 12:10:48 mysqld_safe Starting mysqld daemon with databases from /usr/local/mysql/var
151112 12:10:48 Fatal error: Can't change to run as user 'mysql' ;Please check that the user exists!

151112 12:10:48 Aborting

151112 12:10:48 /usr/local/mysql/libexec/mysqld: Shutdown complete

151112 12:10:48 mysqld_safe mysqld from pid file /usr/local/mysql/var/pub-PowerEdge-R820.pid ended
151112 12:14:55 mysqld_safe Starting mysqld daemon with databases from /usr/local/mysql/var
151112 12:14:55 Fatal error: Can't change to run as user 'mysql' ;Please check that the user exists!

151112 12:14:55 Aborting


ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)



licess 发表于 2015-11-12 17:12:54

检查一下mysql用户和用户组是否存在
没有的话
groupadd mysql
useradd -s /sbin/nologin -M -g mysql mysql
进行添加
再ls -la /usr/local/mysql/bin/
ls -la /usr/local/mysql/var/ 看一下权限

onlyyou 发表于 2017-1-25 11:27:10

请问正常权限应该是什么样的?

再ls -la /usr/local/mysql/bin/
ls -la /usr/local/mysql/var/ 看一下权限
请问正常权限应该是什么样的?

licess 发表于 2017-1-25 12:04:24

回复 3# 的帖子

属主和属组都应该是mysql
页: [1]
查看完整版本: mysql 开启不了