概述
[root@instance-7m3omjg9 /]# systemctl status mysqld
● mysqld.service - MySQL 8.0 database server
Loaded: loaded (/usr/lib/systemd/system/mysqld.service; enabled; vendor preset: disabled)
Active: failed (Result: exit-code) since Fri 2020-08-07 09:47:21 CST; 1min 45s ago
Process: 11782 ExecStopPost=/usr/libexec/mysql-wait-stop (code=exited, status=0/SUCCESS)
Process: 11779 ExecStart=/usr/libexec/mysqld --basedir=/usr (code=exited, status=1/FAILURE)
Process: 11742 ExecStartPre=/usr/libexec/mysql-prepare-db-dir mysqld.service (code=exited, status=0/SUCCESS)
Process: 11718 ExecStartPre=/usr/libexec/mysql-check-socket (code=exited, status=0/SUCCESS)
Main PID: 11779 (code=exited, status=1/FAILURE)
Status: "Server startup in progress"
Error: 2 (No such file or directory)
Aug 07 09:47:20 instance-7m3omjg9 systemd[1]: Starting MySQL 8.0 database server...
Aug 07 09:47:21 instance-7m3omjg9 systemd[1]: mysqld.service: Main process exited, code=exited, status=1/FAILURE
Aug 07 09:47:21 instance-7m3omjg9 systemd[1]: mysqld.service: Failed with result 'exit-code'.
Aug 07 09:47:21 instance-7m3omjg9 systemd[1]: Failed to start MySQL 8.0 database server.
首先检查了 mysqld.log 日志,得到了报错的日志信息
2020-08-07T01:38:36.676475Z 1 [ERROR] [MY-012271] [InnoDB] The innodb_system data file 'ibdata1' must be writable
2020-08-07T01:38:36.676521Z 1 [ERROR] [MY-010334] [Server] Failed to initialize DD Storage Engine
2020-08-07T01:38:36.676691Z 0 [ERROR] [MY-010020] [Server] Data Dictionary initialization failed.
2020-08-07T01:38:36.677724Z 0 [ERROR] [MY-010119] [Server] Aborting
根据日志信息知道了是 ‘ibdata1’ 数据文件必须是可写的
所以更改权限即可
输入
chmod -R 777 /var/lib/mysql
然后重新启动服务
service mysqld start
启动完成后检查服务是否启动成功即可!
最后
以上就是沉静大炮为你收集整理的Linux 搭建 Mysql8 服务器后,出现启动失败的问题的全部内容,希望文章能够帮你解决Linux 搭建 Mysql8 服务器后,出现启动失败的问题所遇到的程序开发问题。
如果觉得靠谱客网站的内容还不错,欢迎将靠谱客网站推荐给程序员好友。
本图文内容来源于网友提供,作为学习参考使用,或来自网络收集整理,版权属于原作者所有。
发表评论 取消回复