CentOS 7启动、重启、chkconfig等命令已经合并为systemctl
作者:
秒速五厘米
service httpd start 启动Apache httpd service httpd restart 重新启动 service httpd stop 停止服务 chkconfig –levels 235 httpd on 开机启动httpd
/etc/init.d/ httpd start 启动 /etc/init.d/ httpd restart 重新启动 /etc/init.d/ httpd stop 停止服务
systemctl 动作 服务名.service
systemctl start httpd.service /启动Apache httpd systemctl restart httpd.service /重新启动 systemctl stop httpd.service /停止服务 systemctl enable httpd.service /开机启动httpd systemctl disable httpd.service /禁止开机启动httpd systemctl status httpd.service /httpd当前状态