关闭所有:
for zdw in `chkconfig --list|grep "5:on"|awk ‘ {print $2}‘ `;do chkconfig $zdw off;done
for zdw in `chkconfig --list|grep "5:on"|awk ‘ {print $1}‘ `;do chkconfig $zdw off;done
for zdw in `chkconfig --list|grep "4:on"|awk ‘ {print $1}‘ `;do chkconfig $zdw off;done
for zdw in `chkconfig --list|grep "2:on"|awk ‘ {print $1}‘ `;do chkconfig $zdw off;done
开启需要的:
for zdw in crond network sshd rsyslog;do chkconfig $zdw on;done
for zdw in crond network sshd rsyslog;do chkconfig $zdw on;done
原文地址:http://itboy168.blog.51cto.com/4476935/1932838