Centos 7 yum install mysql 安装mariadb 后无法启动

前端之家收集整理的这篇文章主要介绍了Centos 7 yum install mysql 安装mariadb 后无法启动前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。

yum install MysqL 显示 MysqL 安装完成,但service MysqL status,service MysqL start 均提示失败,数据库无法登陆。 [root@ansible flask_sqlalchemy]# service MysqL status Redirecting to /bin/systemctl status MysqL.service ● MysqL.service Loaded: not-found (Reason: No such file or directory) Active: inactive (dead) [root@ansible flask_sqlalchemy]# service MysqL start Redirecting to /bin/systemctl start MysqL.service Failed to start MysqL.service: Unit MysqL.service Failed to load: No such file or directory. [root@ansible flask_sqlalchemy]# MysqL -u root ERROR 2002 (HY000): Can't connect to local MysqL server through socket '/var/lib/MysqL/MysqL.sock' (2) 解决方法

yum install mariadb-server -y

systemctl start mariadb.service

systemctl enable mariadb.service

MysqL 参考:http://www.centoscn.com/CentosBug/softbug/2016/0115/6660.html 数据库可以登陆,但是service MysqL 仍然提示上述错误,原因还需进一步分析。

原文链接:https://www.f2er.com/centos/375186.html

猜你在找的CentOS相关文章