首页 > 其他 > 详细

nginx平滑升级make upgrade出错的解决办法

时间:2014-03-05 23:37:16      阅读:1123      评论:0      收藏:0      [点我收藏+]

为nginx平滑升级在make upgrate那一步除了点小状况



[root@web01 nginx-1.0.5]# make upgrade
/usr/local/nginx/sbin/nginx -t
nginx: the configuration file /usr/local/nginx/conf/nginx.conf syntax is ok
nginx: configuration file /usr/local/nginx/conf/nginx.conf test is successful
kill -USR2 `cat /usr/local/nginx/logs/nginx.pid`
sleep 1
test -f /usr/local/nginx/logs/nginx.pid.oldbin
make: *** [upgrade] 错误 1
[root@web01 nginx-1.0.5]#


找不到进程文件出错,无法进行下一步


再次启动脚本,有如下提示


[root@web01 sbin]# ./nginxold
[emerg]: bind() to 0.0.0.0:80 failed (98: Address already in use)
[emerg]: bind() to 0.0.0.0:80 failed (98: Address already in use)
[emerg]: bind() to 0.0.0.0:80 failed (98: Address already in use)
[emerg]: bind() to 0.0.0.0:80 failed (98: Address already in use)
[emerg]: bind() to 0.0.0.0:80 failed (98: Address already in use)
[emerg]: still could not bind()

这步是说80端口被使用


我也不清楚为什么nginx启动了却没有进程文件。

所以先把nginx kill掉,重新启动


[root@web01 sbin]# pkill -int nginx
[root@web01 sbin]# ./nginxold    
[root@web01 sbin]#



接着make upgrate就成功了升级


[root@web01 nginx-1.0.5]# make upgrade
/usr/local/nginx/sbin/nginx -t
nginx: the configuration file /usr/local/nginx/conf/nginx.conf syntax is ok
nginx: configuration file /usr/local/nginx/conf/nginx.conf test is successful
kill -USR2 `cat /usr/local/nginx/logs/nginx.pid`
sleep 1
test -f /usr/local/nginx/logs/nginx.pid.oldbin
kill -QUIT `cat /usr/local/nginx/logs/nginx.pid.oldbin`
[root@web01 nginx-1.0.5]#
[root@web01 nginx-1.0.5]#



希望对大家有帮助





本文出自 “小风” 博客,请务必保留此出处http://huanglianfeng.blog.51cto.com/4813074/1368859

nginx平滑升级make upgrade出错的解决办法,布布扣,bubuko.com

nginx平滑升级make upgrade出错的解决办法

原文:http://huanglianfeng.blog.51cto.com/4813074/1368859

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!