Nginx的启动、停止、平滑重启
分类:运维技术日期:2012-02-24 - 22:42:34评论:4条作者:老谢
启动Nginx
/usr/local/nginx/sbin/nginx -c /usr/local/nginx/conf/nginx.conf
停止Nginx
可以发送向通信号给Nginx主进程的方式来停止Nginx,操作如下:
CentOS release 5.7 (Final)
[root@vps ~]# ps -ef | grep nginx #查询master process主进程号
root 3266 1 0 Feb20 ? 00:00:00 nginx: master process /usr/local/nginx/sbin/nginx -c /usr/local/nginx/conf/nginx.conf
nobody 3267 3266 0 Feb20 ? 00:00:01 nginx: worker process
root 9282 9239 0 20:51 pts/0 00:00:00 grep nginx
[root@vps ~]# kill -QUIT 3266 #从容停止Nginx
root 3266 1 0 Feb20 ? 00:00:00 nginx: master process /usr/local/nginx/sbin/nginx -c /usr/local/nginx/conf/nginx.conf
nobody 3267 3266 0 Feb20 ? 00:00:01 nginx: worker process
root 9282 9239 0 20:51 pts/0 00:00:00 grep nginx
[root@vps ~]# kill -QUIT 3266 #从容停止Nginx
最新评论
zwwooooo:买特斯拉和买iPhone的人群其实相似...
平安家属子痕:一直坚持油车,看你写的心里有...
秦大叔:室内每年能开2万公里电车确实划算 ...
灰常记忆:尊贵的特斯拉车主啊,对了一直对单...
拳废神域界:我的车现在平常跑不了啥,就放假...
大峰:电车起步超级快,我油车反正是跟不上,...
Mr.Chou:电车高速上真120和油车120真的有区...
Mr.Chou:18 19年入手的房子现在死的心都有了...
老何:不至于跌得这么狠吧
Andy烧麦:这些大厂都能提供必要的售后