nginx proxy超时报错 upstream timed out (110: Connec...

环境介绍 
服务器:centos6.4
服务:nginx proxy

问题描述:

然后查找  /opt/usr/nginx/1.4.0/logs  错误 error.log日志提示如下

2015/01/04 15:44:13 [error] 10112#0: *994662 upstream timed out (110: Connection timed out) while reading response header from upstream, client: 117.32.232.172, server: localhost, request: "POST /community-platform/datastatistics/datastatistics_exportAllUserDataDetail.action HTTP/1.1", upstream: "http://10.172.11.194:9080/community-platform/datastatistics/datastatistics_exportAllUserDataDetail.action", host: "admin.zhsqcn.com", referrer: "http://admin.zhsqcn.com/community-platform/datastatistics/datastatistics_communityStatistics.action?leftPid=98"
2015/01/04 15:45:22 [info] 10112#0: *994692 client closed connection while waiting for request, client: 117.32.232.172, server: 0.0.0.0:80

2015/01/04 15:57:10 [info] 10112#0: *994707 client 1.85.57.66 closed keepalive connection
2015/01/04 15:57:19 [info] 10112#0: *994711 client 1.85.57.66 closed keepalive connection
2015/01/04 15:57:19 [info] 10112#0: *994718 client closed connection while waiting for request, client: 1.85.57.66, server: 0.0.0.0:80

 

解决方法:vi  /opt/usr/nginx/1.4.0/conf/nginx.conf
原因在于nginx proxy的超时时间太短
proxy_connect_timeout    3;
proxy_read_timeout       30;
proxy_send_timeout       30;

更改为

proxy_connect_timeout    600;
proxy_read_timeout       600;
proxy_send_timeout       600;

然后重启nginx即可:

/opt/usr/nginx/1.4.0/sbin/nginx -s reload

转载于:https://www.cnblogs.com/zhangkaimin/p/4201453.html

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值