1、通知nginx将pid文件改名为nginx.pid.oldbin,并启动新的nginx
kill -USR2 `cat /usr/local/nginx/logs/nginx.pid`
2、通知旧的nginx平滑关闭工作进程(可以不用)
kill -WINCH `cat /usr/local/nginx/logs/nginx.pid.oldbin`
3、通知旧的nginx平滑退出
kill -QUIT `cat /usr/local/nginx/logs/nginx.pid.oldbin`
4、如果临时决定关掉新的nginx,保留旧的nginx,可以
kill -QUIT `cat /usr/local/nginx/logs/nginx.pid`