欢迎您访问程序员文章站本站旨在为大家提供分享程序员计算机编程知识!
您现在的位置是: 首页

chkconfig: command not found

程序员文章站 2022-07-12 14:00:35
...

问题描述:

ubuntu1~16.04.10 执行 chkconfig 命令报 chkconfig: command not found 说明此服务上没有安装 chkconfig。执行如下命令进行安装

apt-get update
apt-get install chkconfig

但是在安装时,安装失败出现如下问题:

Reading package lists… Done
Building dependency tree
Reading state information… Done
Package chkconfig is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source

E: Package ‘chkconfig’ has no installation candidate

问题原因:

查询说是在 ubuntu1~16.04.10 使用 sysv-rc-conf 代替了 chkconfig

解决方法:

执行如下命令安装 sysv-rc-conf.

apt-get update
apt-get install sysv-rc-conf