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. 1005 Spell It Right (20 分)

    1005 Spell It Right (20 分) Given a non-negative integer N, your task is to compute the sum of all th ...

  2. PLSQL导出表结构

    1:进行plsql后选怎Tools--------->Exports User Ojbects------------->选中需要导出的table,squence,view,type,fu ...

  3. Spark学习笔记6:Spark调优与调试

    1.使用Sparkconf配置Spark 对Spark进行性能调优,通常就是修改Spark应用的运行时配置选项. Spark中最主要的配置机制通过SparkConf类对Spark进行配置,当创建出一个 ...

  4. php trim() 函数实例讲解

    php trim() 函数移除字符串两侧的空白字符或其他预定义字符,本文章向码农介绍php trim() 函数的使用方法和实例,感兴趣的码农可以参考一下. 定义和用法 trim() 函数移除字符串两侧 ...

  5. 小朋友学Python(1):Python简介与编程环境搭建

    一.Python简介 不死Java,不朽C/C++,新贵Python. Python(英国发音:/ˈpaɪθən/ 美国发音:/ˈpaɪθɑːn/), 是一种面向对象的解释型计算机程序设计语言,由荷兰 ...

  6. Java集合入门

    内容: 1.认识集合 2.Iterator迭代器 1.认识集合 (1)什么是集合 前面的学习,我们知道数据多了,使用数组存放.而且数组中存放的都是基本类型的数据,并且数组是定长的. 当在程序中创建的对 ...

  7. selenium+python自动化90-unittest多线程执行用例

    前言 假设执行一条脚本(.py)用例一分钟,那么100个脚本需要100分钟,当你的用例达到一千条时需要1000分钟,也就是16个多小时... 那么如何并行运行多个.py的脚本,节省时间呢?这就用到多线 ...

  8. laravel5.4中ajax删除数据

    1 JS代码 function deleteInfo(id) { if(id) { var r=confirm('确定要删除吗'); if(r==true) { $.ajax({ url: " ...

  9. JPA注解@SecondaryTables 实现一个实体映射多张数据库表

    参考:http://jingpin.jikexueyuan.com/article/46978.html Annotation Type SecondaryTables(参考:https://docs ...

  10. Activity服务类-2 EngineService服务类

    一共提供了9个接口 //获取RepositoryServiceRepositoryService getRepositoryService();//获取RuntimeServiceRuntimeSer ...