ubuntu 如何安装 sysv-rc-conf 配置chkconfig
问题:
[email protected]:/home/lwb# chkconfig mysql on
chkconfig: command not found #没有安装chkcofig
方案:
第一步:[email protected]:/home/lwb# vim /etc/apt/sources.list
在这个文档中得最后一行添加如下文本:
deb http://archive.ubuntu.com/ubuntu/ trusty main universe restricted multiverse
第二步:更新apt-get,在终端输入sudo apt-get update
第三步:完成更新后,重新安装sysv-rc-conf,在终端输入sudo apt-get install sysv-rc-conf,即可成功安装。
第四步:ls /usr/sbin | grep sysv #确认是否存在
第五步:更名
cp /usr/sbin/sysv-rc-conf /usr/sbin/chkconfig
ls /usr/sbin | grep chk #确认修改成功
第六步:#赋予权限
cd /usr/sbin
chmod 755 chkconfig
第七步:#测试一下
chkconfig