-
1、编写脚本,名为nginx
-
2、加入chkconfig
[root@example ~]# cp nginx /etc/init.d/
[root@example ~]# chmod 755 /etc/init.d/nginx
[root@example ~]# chkconfig --add nginx3、nginx启动、停止、无间断服务重启
[root@example ~]# service nginx start
[root@example ~]# service nginx stop
[root@example ~]# service nginx reload
把nginx加入到系统服务,利用chkconfig控制
最新推荐文章于 2025-02-22 14:51:03 发布