Centos7执行systemctl start 服务报Centos7 Failed to start xxx.service: Unit not found

1585364631
2022-01-23 / 0 评论 / 462 阅读 / 正在检测是否收录...
温馨提示:
本文最后更新于2022年01月23日,已超过1541天没有更新,若内容或图片失效,请留言反馈。

AI摘要

CentOS 7执行systemctl启动服务报错“Unit not found”时,首先应使用`systemctl list-unit-files`命令确认服务是否存在。若存在,尝试执行`systemctl daemon-reload`重新加载配置;若不存在,则需重新安装该服务。

Centos7执行systemctl start 服务报Centos7 Failed to start xxx.service: Unit not found

查看列表中是否有该服务

systemctl list-unit-files --type=service

可配合| grep搜索

systemctl list-unit-files --type=service | grep 服务

如果有则执行命令重新读取

systemctl daemon-reload

如果没有则自行重装

0

评论 (0)

取消