装上后,发现是装的最小版本好多命令不能用。
借鉴这篇文章http://www.linuxidc.com/Linux/2014-08/105682.htm可以举一反三啊。
不能够用的命令均可以用。举个service的例子
yum provides service
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
* base: mirrors.aliyun.com
* extras: mirrors.yun-idc.com
* updates: mirrors.aliyun.com
base/7/x86_64/filelists_db | 6.0 MB 00:00:01
extras/7/x86_64/filelists_db | 186 kB 00:00:00
updates/7/x86_64/filelists_db | 2.2 MB 00:00:00
initscripts-9.49.24-1.el7.x86_64 : The inittab file and the /etc/init.d scripts
Repo : base
Matched from:
Filename : /sbin/service
安装initscripts即可
yum install initscripts
完成后service
Usage: service < option > | --status-all | [ service_name [ command | --full-restart ] ]
ok了
其实service还是不能,centos7 service其实是调用systemctl接着安装吧