nginx 作为负载服务,表现为网站访问很慢,有些文件或页面要等待到60s才会返回,我注意到60s就是超时时间,但是超时后返回状态是正常值200,网站可以正常打开,就是会一直等待到超时才打开,而且问题出现不定时,不定文件,静态文件也会出现这个问题。貌似很奇葩是吧,最终查看错误信息没有注意到 IPv6,导致饶了不少弯。

错误信息:

[error] #: * upstream timed out (: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond) while connecting to upstream, client: 66.249.69.219, server: xxx.com, request: "GET /shop/view.jhtml HTTP/1.1", upstream: "http://[::1]:12002/shop/view.jhtml", host: "www.xxx.com"

配置如下:

    upstream zcun_pool {
server localhost: max_fails= fail_timeout=30s;
server localhost: max_fails= fail_timeout=30s;
server localhost: max_fails= fail_timeout=30s;
}

发现可能是 IPv6 的问题后,改 localhost 为本地 IPv4 即可解决.....这错误说起来还真是低级~

    upstream zcun_pool {
server 127.0.0.1: max_fails= fail_timeout=30s;
server 127.0.0.1: max_fails= fail_timeout=30s;
server 127.0.0.1: max_fails= fail_timeout=30s;
}

网站访问回复正常。

nginx 的 upstream timed out 问题的更多相关文章

  1. nginx错误Upstream timed out

    Upstream timed out (110: Connection timed out) while reading response header from upstream 这种情况主要在下面 ...

  2. nginx 报错 upstream timed out (110: Connection timed out)解决方案

    nginx 作PHP的web接口服务器. 在线上发现时不时经常崩溃.504,导致接口访问无响应回复. 查看日志: [error] 11618#0: *324911 upstream timed out ...

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

    环境介绍 服务器:centos6.4服务:nginx proxy 问题描述: 然后查找  /opt/usr/nginx/1.4.0/logs  错误 error.log日志提示如下 2015/01/0 ...

  4. nginx+webpy 出现 upstream timed out

    关于nginx配置webpy应用出现的错误 upstream timed out (: Connection timed out) while reading response header from ...

  5. nginx 报错 upstream timed out (110: Connection timed out)解决方案【转】

    转自 nginx 报错 upstream timed out (110: Connection timed out)解决方案 - 为程序员服务http://outofmemory.cn/code-sn ...

  6. Nginx报错:upstream timed out (110: Connection timed out)和client intended to send too large body【转】

    nginx日志报错 2018/01/26 16:36:49 [error] 23327#0: *54953 upstream timed out (110: Connection timed out) ...

  7. Nginx Upstream timed out (110: Connection timed out)

    Nginx Upstream timed out (110: Connection timed out) – 运维生存时间 http://www.ttlsa.com/nginx/nginx-upstr ...

  8. nginx 超时问题: upstream timed out (110: Connection timed out) while reading response header from upstream

    目录 错误内容 错误原因 错误解决办法 错误内容 我们可以在error.log 里面可以看到 错误内容:upstream timed out (110: Connection timed out) w ...

  9. nginx响应超时upstream timed out 问题处理

    环境介绍 服务器:centos7.2 应用:tomcat集群 服务:nginx 代理 问题描述: 这段时间,听项目组项目经理和业务需求人员跟我反馈,线上业务人员在操作业务交易时,有时会出现nginx错 ...

随机推荐

  1. Storm存储结果至Redis

      原有的事务支持使用MemcachedState来进行,现在需要将其迁移至Redis,并且需要记录所有key值列表,因为在redis中虽然可以使用keys *操作,但不是被推荐的方式,所以把所有结果 ...

  2. [UE4]运行时UMG组件跟随鼠标的逻辑:拖拽UMG组件(蓝图)

    转自:http://aigo.iteye.com/blog/2279860 UMG - Mouse screen position problem https://forums.unrealengin ...

  3. sqoop操作之HIVE导出到ORACLE

    示例数据准备 hive中创建dept表 create table dept( deptno int, dname string, loc string ) row format delimited f ...

  4. Centos7下单机部署Solr7.3

    本章重点介绍CentOS7 下部署Solr7 ,添加核心Core配置,Dataimport导入,中文分词的相关操作. 一.准备工作     演示环境是在虚拟机下安装的CentOS7.java JDK8 ...

  5. VSCode编辑器编写Python代码

    如何用VSCode愉快的写Python https://code.visualstudio.com/   在学习Python的过程中,一直没有找到比较趁手的第三方编辑器,用的最多的还是Python自带 ...

  6. Mac OS 修改hosts文件

    这里用得是 VI 编辑器修改 打开终端(应用程序——实用工具),运行: sudo vi /etc/hosts,此时屏幕上会提示你输入密码 打开 hosts 文件之后按 i 键进入插入模式(可理解为编辑 ...

  7. python之集合操作

    1.集合的增操作 add(item):增加至集合中 update(set):  若不存在,更新至集合中 2.集合的删操作(五种) pop():  随机删除并返回值 remove(item): 删除va ...

  8. java开发-问题清单

    本人是做Java开发的,这是我参加58,搜狐,搜狗,新浪微博,百度,腾讯文学,网易以及其他一些小的创业型公司的面试常被问的问题,当然有重复,弄清楚这些 1. junit用法,before,before ...

  9. as3 代码优化

    1 代码写法 1 定义局部变量 定义局部变量的时候,一定要用关键字var来定义,因为在Flash播放器中,局部变量的运行速度更快,而且在他们的作用域外是不耗占系统资源的.当一个函数调用结束的时候,相应 ...

  10. 快速可靠网络传输协议 KCP(转)

    KCP 是一个快速可靠协议,能以比 TCP浪费10%-20%的带宽的代价,换取平均延迟降低30%-40%,且最大延迟降低三倍的传输效果.纯算法实现,并不负责底层协议(如UDP)的收发,需要使用者自己定 ...