首页 > 代码库 > mysqld服务启动失败, Failed to restart mysqld.service: Unit not found.
mysqld服务启动失败, Failed to restart mysqld.service: Unit not found.
-bash-4.2# service mysqld restart
Redirecting to /bin/systemctl restart mysqld.service
Failed to restart mysqld.service: Unit not found.
并不存在 mysqld 的服务,
-bash-4.2# -bash-4.2# chkconfig -list-list: unknown option-bash-4.2# chkconfig --listNote: This output shows SysV services only and does not include native systemd services. SysV configuration data might be overridden by native systemd configuration. If you want to list systemd services use ‘systemctl list-unit-files‘. To see services enabled on particular target use ‘systemctl list-dependencies [target]‘.aegis 0:off 1:off 2:on 3:on 4:on 5:on 6:offagentwatch 0:off 1:off 2:on 3:on 4:on 5:on 6:offiprdump 0:off 1:off 2:on 3:on 4:on 5:on 6:offiprinit 0:off 1:off 2:on 3:on 4:on 5:on 6:offiprupdate 0:off 1:off 2:on 3:on 4:on 5:on 6:offjexec 0:off 1:on 2:on 3:on 4:on 5:on 6:offmysql.server 0:off 1:off 2:on 3:on 4:on 5:on 6:offnetconsole 0:off 1:off 2:off 3:off 4:off 5:off 6:offnetwork 0:off 1:off 2:on 3:on 4:on 5:on 6:off
可见,服务名不是mysqld 而是 mysql.server
于是:
-bash-4.2# service mysql.server restart
Shutting down MySQL....[ OK ]
Starting MySQL.[ OK ]
mysqld服务启动失败, Failed to restart mysqld.service: Unit not found.
声明:以上内容来自用户投稿及互联网公开渠道收集整理发布,本网站不拥有所有权,未作人工编辑处理,也不承担相关法律责任,若内容有误或涉及侵权可进行投诉: 投诉/举报 工作人员会在5个工作日内联系你,一经查实,本站将立刻删除涉嫌侵权内容。