根据这个提示,查看原因,百度到的办法是,修改配置文件后,还是报错“Job for mysqld.service failed because the control process exited with error code”。之后发现这一个问题(红框里面的提示,一开始就忽略了。。。导致走弯路),开始根据这个提示来寻找办法:

MySQL——Job for mysqld.service failed because the control process exited with error code问题

最后查看日志,发现是因为没有下面这个表,需要对MySQL文件夹做一个初始化:

MySQL——Job for mysqld.service failed because the control process exited with error code问题

提示不能初始化,最后发现是/var/lib/mysql /这个目标路径已经存在/var/lib/mysql /,导致无法初始化。解决办法:

MySQL——Job for mysqld.service failed because the control process exited with error code问题

删除/var/lib/mysql /后重启MySQL服务就可以了!

MySQL——Job for mysqld.service failed because the control process exited with error code问题

 

相关文章:

  • 2021-10-30
  • 2021-09-27
  • 2021-04-12
  • 2021-06-27
  • 2021-09-27
  • 2022-12-23
  • 2021-07-31
  • 2022-01-23
猜你喜欢
  • 2022-12-23
  • 2021-10-07
  • 2021-11-13
  • 2021-12-25
  • 2021-04-19
  • 2021-07-23
相关资源
相似解决方案