目前已知的情况如下:
我有一台测试环境服务器和这台报错的环境是一致的(都是通过yum安装的), 在测试环境就没有出现这个error, 版本如下:
nginx version: nginx/1.6.3
PHP 7.0.11 (fpm-fcgi) (built: Sep 17 2016 12:55:16)
Copyright (c) 1997-2016 The PHP Group
Zend Engine v3.0.0, Copyright (c) 1998-2016 Zend Technologies
with Zend OPcache v7.0.11, Copyright (c) 1999-2016, by Zend Technologies
我把测试环境(正常运行环境)的配置文件整个拷贝到正式环境(运行异常环境)后, 问题依旧, 囧...
不过初步应该可以确定不是配置文件的问题了
php-fpm 中没有看到任何error信息
尝试如下:
大部分都是说这个问题, 但是然并卵: http://blog.csdn.net/dazhi_100/article/details/49096213
这里有个一毛一样的问题, 但并没有说什么原因导致的: https://github.com/openresty/lua-nginx-module/issues/848
有大兄弟遇到和我一样问题的吗?
nginx debug日志如下:
2016/10/17 17:15:07 [info] 7047#0: *622 recv() failed (104: Connection reset by peer) while waiting for request, client: 100.109.211.0, server: 0.0.0.0:80
2016/10/17 17:15:07 [info] 7047#0: *620 recv() failed (104: Connection reset by peer) while waiting for request, client: 100.109.209.0, server: 0.0.0.0:80
2016/10/17 17:15:07 [debug] 7047#0: *620 close http connection: 28
2016/10/17 17:15:07 [debug] 7047#0: *620 event timer del: 28: 1476695767331
2016/10/17 17:15:07 [debug] 7047#0: *620 reusable connection: 0
2016/10/17 17:15:07 [debug] 7047#0: *620 free: 0000000001C3BAE0
2016/10/17 17:15:07 [debug] 7047#0: *620 free: 0000000001CB9330, unused: 0
2016/10/17 17:15:07 [debug] 7047#0: *620 free: 0000000001CB9440, unused: 120
2016/10/17 17:15:07 [debug] 7047#0: posted event 0000000000000000
2016/10/17 17:15:07 [debug] 7047#0: worker cycle
2016/10/17 17:15:07 [debug] 7047#0: accept mutex locked
2016/10/17 17:15:07 [debug] 7047#0: epoll timer: 40915
2016/10/17 17:15:07 [debug] 7048#0: timer delta: 501
2016/10/17 17:15:07 [debug] 7048#0: posted events 0000000000000000
2016/10/17 17:15:07 [debug] 7048#0: worker cycle
2016/10/17 17:15:07 [debug] 7048#0: accept mutex lock failed: 0
2016/10/17 17:15:07 [debug] 7048#0: epoll timer: 500
2016/10/17 17:15:07 [debug] 7047#0: epoll: fd:10 ev:0001 d:00007F32B02DE010
2016/10/17 17:15:07 [debug] 7047#0: post event 00007F32AFC5E010
2016/10/17 17:15:07 [debug] 7047#0: timer delta: 46
2016/10/17 17:15:07 [debug] 7047#0: posted event 00007F32AFC5E010
2016/10/17 17:15:07 [debug] 7047#0: delete posted event 00007F32AFC5E010
2016/10/17 17:15:07 [debug] 7047#0: accept on 0.0.0.0:80, ready: 0
2016/10/17 17:15:07 [debug] 7047#0: posix_memalign: 0000000001CB9330:256 @16
2016/10/17 17:15:07 [debug] 7047#0: *621 accept: 100.109.210.0 fd:28
2016/10/17 17:15:07 [debug] 7047#0: posix_memalign: 0000000001CB9440:256 @16
2016/10/17 17:15:07 [debug] 7047#0: *621 event timer add: 28: 60000:1476695767377
2016/10/17 17:15:07 [debug] 7047#0: *621 reusable connection: 1
2016/10/17 17:15:07 [debug] 7047#0: *621 epoll add event: fd:28 op:1 ev:80002001
2016/10/17 17:15:07 [debug] 7047#0: posted event 0000000000000000
2016/10/17 17:15:07 [debug] 7047#0: posted events 0000000000000000
2016/10/17 17:15:07 [debug] 7047#0: worker cycle
2016/10/17 17:15:07 [debug] 7047#0: accept mutex locked
2016/10/17 17:15:07 [debug] 7047#0: epoll timer: 40869
2016/10/17 17:15:07 [debug] 7047#0: epoll: fd:28 ev:2019 d:00007F32B02DEBE0
2016/10/17 17:15:07 [debug] 7047#0: epoll_wait() error on fd:28 ev:2019
2016/10/17 17:15:07 [debug] 7047#0: *621 post event 00007F32AFC5E5C0
2016/10/17 17:15:07 [debug] 7047#0: timer delta: 0
2016/10/17 17:15:07 [debug] 7047#0: posted events 00007F32AFC5E5C0
2016/10/17 17:15:07 [debug] 7047#0: posted event 00007F32AFC5E5C0
2016/10/17 17:15:07 [debug] 7047#0: *621 delete posted event 00007F32AFC5E5C0
2016/10/17 17:15:07 [debug] 7047#0: *621 http wait request handler
2016/10/17 17:15:07 [debug] 7047#0: *621 malloc: 0000000001C3BAE0:16384
2016/10/17 17:15:07 [debug] 7047#0: *621 recv: fd:28 -1 of 16384
2016/10/17 17:15:07 [info] 7047#0: *621 recv() failed (104: Connection reset by peer) while waiting for request, client: 100.109.210.0, server: 0.0.0.0:80
2016/10/17 17:15:07 [debug] 7047#0: *621 close http connection: 28
2016/10/17 17:15:07 [debug] 7047#0: *621 event timer del: 28: 1476695767377
2016/10/17 17:15:07 [debug] 7047#0: *621 reusable connection: 0
2016/10/17 17:15:07 [debug] 7047#0: *621 free: 0000000001C3BAE0
2016/10/17 17:15:07 [debug] 7047#0: *621 free: 0000000001CB9330, unused: 0
2016/10/17 17:15:07 [debug] 7047#0: *621 free: 0000000001CB9440, unused: 120
2016/10/17 17:15:07 [debug] 7047#0: posted event 0000000000000000
2016/10/17 17:15:07 [debug] 7047#0: worker cycle
2016/10/17 17:15:07 [debug] 7047#0: accept mutex locked
2016/10/17 17:15:07 [debug] 7047#0: epoll timer: 40869
2016/10/17 17:15:07 [debug] 7047#0: epoll: fd:10 ev:0001 d:00007F32B02DE010
2016/10/17 17:15:07 [debug] 7047#0: post event 00007F32AFC5E010
2016/10/17 17:15:07 [debug] 7047#0: timer delta: 44
2016/10/17 17:15:07 [debug] 7047#0: posted event 00007F32AFC5E010
2016/10/17 17:15:07 [debug] 7047#0: delete posted event 00007F32AFC5E010
2016/10/17 17:15:07 [debug] 7047#0: accept on 0.0.0.0:80, ready: 0
2016/10/17 17:15:07 [debug] 7047#0: posix_memalign: 0000000001CB9330:256 @16
2016/10/17 17:15:07 [debug] 7047#0: *622 accept: 100.109.211.0 fd:28
2016/10/17 17:15:07 [debug] 7047#0: posix_memalign: 0000000001CB9440:256 @16
2016/10/17 17:15:07 [debug] 7047#0: *622 event timer add: 28: 60000:1476695767421
2016/10/17 17:15:07 [debug] 7047#0: *622 reusable connection: 1
2016/10/17 17:15:07 [debug] 7047#0: *622 epoll add event: fd:28 op:1 ev:80002001
2016/10/17 17:15:07 [debug] 7047#0: posted event 0000000000000000
2016/10/17 17:15:07 [debug] 7047#0: posted events 0000000000000000
2016/10/17 17:15:07 [debug] 7047#0: worker cycle
2016/10/17 17:15:07 [debug] 7047#0: accept mutex locked
2016/10/17 17:15:07 [debug] 7047#0: epoll timer: 40825
2016/10/17 17:15:07 [debug] 7047#0: epoll: fd:28 ev:2019 d:00007F32B02DEBE1
2016/10/17 17:15:07 [debug] 7047#0: epoll_wait() error on fd:28 ev:2019
2016/10/17 17:15:07 [debug] 7047#0: *622 post event 00007F32AFC5E5C0
2016/10/17 17:15:07 [debug] 7047#0: timer delta: 0
2016/10/17 17:15:07 [debug] 7047#0: posted events 00007F32AFC5E5C0
2016/10/17 17:15:07 [debug] 7047#0: posted event 00007F32AFC5E5C0
2016/10/17 17:15:07 [debug] 7047#0: *622 delete posted event 00007F32AFC5E5C0
2016/10/17 17:15:07 [debug] 7047#0: *622 http wait request handler
2016/10/17 17:15:07 [debug] 7047#0: *622 malloc: 0000000001C3BAE0:16384
2016/10/17 17:15:07 [debug] 7047#0: *622 recv: fd:28 -1 of 16384
2016/10/17 17:15:07 [info] 7047#0: *622 recv() failed (104: Connection reset by peer) while waiting for request, client: 100.109.211.0, server: 0.0.0.0:80
2016/10/17 17:15:07 [debug] 7047#0: *622 close http connection: 28
2016/10/17 17:15:07 [debug] 7047#0: *622 event timer del: 28: 1476695767421
2016/10/17 17:15:07 [debug] 7047#0: *622 reusable connection: 0
2016/10/17 17:15:07 [debug] 7047#0: *622 free: 0000000001C3BAE0
2016/10/17 17:15:07 [debug] 7047#0: *622 free: 0000000001CB9330, unused: 0
2016/10/17 17:15:07 [debug] 7047#0: *622 free: 0000000001CB9440, unused: 120
2016/10/17 17:15:07 [debug] 7047#0: posted event 0000000000000000
2016/10/17 17:15:07 [debug] 7047#0: worker cycle
2016/10/17 17:15:07 [debug] 7047#0: accept mutex locked
2016/10/17 17:15:07 [debug] 7047#0: epoll timer: 40825
2016/10/17 17:15:07 [debug] 7047#0: epoll: fd:10 ev:0001 d:00007F32B02DE010
2016/10/17 17:15:07 [debug] 7047#0: post event 00007F32AFC5E010
2016/10/17 17:15:07 [debug] 7047#0: timer delta: 36
2016/10/17 17:15:07 [debug] 7047#0: posted event 00007F32AFC5E010
2016/10/17 17:15:07 [debug] 7047#0: delete posted event 00007F32AFC5E010
2016/10/17 17:15:07 [debug] 7047#0: accept on 0.0.0.0:80, ready: 0
2016/10/17 17:15:07 [debug] 7047#0: posix_memalign: 0000000001CB9330:256 @16
2016/10/17 17:15:07 [debug] 7047#0: *623 accept: 100.109.216.0 fd:28
2016/10/17 17:15:07 [debug] 7047#0: posix_memalign: 0000000001CB9440:256 @16
2016/10/17 17:15:07 [debug] 7047#0: *623 event timer add: 28: 60000:1476695767457
2016/10/17 17:15:07 [debug] 7047#0: *623 reusable connection: 1
2016/10/17 17:15:07 [debug] 7047#0: *623 epoll add event: fd:28 op:1 ev:80002001
2016/10/17 17:15:07 [debug] 7047#0: posted event 0000000000000000
2016/10/17 17:15:07 [debug] 7047#0: posted events 0000000000000000
2016/10/17 17:15:07 [debug] 7047#0: worker cycle
2016/10/17 17:15:07 [debug] 7047#0: accept mutex locked
2016/10/17 17:15:07 [debug] 7047#0: epoll timer: 40789
2016/10/17 17:15:07 [debug] 7047#0: epoll: fd:28 ev:2019 d:00007F32B02DEBE0
2016/10/17 17:15:07 [debug] 7047#0: epoll_wait() error on fd:28 ev:2019
2016/10/17 17:15:07 [debug] 7047#0: *623 post event 00007F32AFC5E5C0
2016/10/17 17:15:07 [debug] 7047#0: timer delta: 1
2016/10/17 17:15:07 [debug] 7047#0: posted events 00007F32AFC5E5C0
2016/10/17 17:15:07 [debug] 7047#0: posted event 00007F32AFC5E5C0
2016/10/17 17:15:07 [debug] 7047#0: *623 delete posted event 00007F32AFC5E5C0
2016/10/17 17:15:07 [debug] 7047#0: *623 http wait request handler
2016/10/17 17:15:07 [debug] 7047#0: *623 malloc: 0000000001C3BAE0:16384
2016/10/17 17:15:07 [debug] 7047#0: *623 recv: fd:28 -1 of 16384
2016/10/17 17:15:07 [info] 7047#0: *623 recv() failed (104: Connection reset by peer) while waiting for request, client: 100.109.216.0, server: 0.0.0.0:80
你是发生在接受请求,我是发生在等待应答。上游服务跑的很流畅,初步怀疑是连接被系统干掉了。还没找到原因
您好,
好象是网络相关的,外网连接本地 80
端口时,会提示连接被重置的吗?
您好,
好象是网络相关的。
版权声明:本文内容由阿里云实名注册用户自发贡献,版权归原作者所有,阿里云开发者社区不拥有其著作权,亦不承担相应法律责任。具体规则请查看《阿里云开发者社区用户服务协议》和《阿里云开发者社区知识产权保护指引》。如果您发现本社区中有涉嫌抄袭的内容,填写侵权投诉表单进行举报,一经查实,本社区将立刻删除涉嫌侵权内容。