解决CentOS下service 功能 不能使用 bash: service: command not found
时间:2020-02-15 00:25:18
收藏:0
阅读:100
首先检查自己是否 使用的是root用户
在centos系统中,如果/sbin目录下没有service这个命令,就会出现
bash: service: command not found
解决步骤如下:
1、 输入
yum list | grep initscripts
会出现:
initscripts.x86_64

(其实一共有三个信息,但是后面根据版本不同,显示的信息也不同)
2、 上面给出了可安装软件的yum源版本,然后执行
yum install initscripts -y

3、 此时service命令就可用了
原文:https://www.cnblogs.com/LiuChang-blog/p/12310312.html
评论(0)