网站 time_connect 耗时特别长 - V2EX
V2EX = way to explore
V2EX 是一个关于分享和探索的地方
Sign Up Now
For Existing Member  Sign In
xi_lin

网站 time_connect 耗时特别长

  •  
  •   xi_lin Feb 6, 2018 2648 views
    This topic created in 3005 days ago, the information mentioned may be changed or developed.

    用 curl 记录了一次请求过程

    -w 的参数如下

     1 time_namelookup: %{time_namelookup}\n 2 time_connect: %{time_connect}\n 3 time_appconnect: %{time_appconnect}\n 4 time_pretransfer: %{time_pretransfer}\n 5 time_redirect: %{time_redirect}\n 6 time_starttransfer: %{time_starttransfer}\n 7 ----------\n 8 time_total: %{time_total}\n 

    输出结果如下

    time_namelookup: 1.527089 time_connect: 68.941406 time_appconnect: 68.989708 time_pretransfer: 68.989782 time_redirect: 0.000000 time_starttransfer: 68.997972 ---------- time_total: 68.998156 

    这个 time_connect 花了特别长的时间。不知道一般会是啥配置导致的呢?

    服务端用的 Tengine,快的时候几毫秒就能返回结果,慢的时候就像上面这个结果一样。

    Supplement 1    Feb 6, 2018
    看到一个类似的问题分析
    https://ifengkou.github.io/httpstat.html

    但是这文章我没看懂到底结论是啥,怎么处理
    2 replies    2018-10-13 13:37:05 +08:00
    tingyunsay
        1
    tingyunsay  
       Oct 12, 2018
    楼主你最后解决了这个问题吗?我之前一台机器也是这样的,重启之后就变成了这个 b 样,只针对某一些网站出现这种大量超时,都是耗费在 time_connect 上....
    xi_lin
        2
    xi_lin  
    OP
       Oct 13, 2018
    我们后来加了个阿里云的 slb 好像就变好了,感觉还是网络的问题
    About     Help     Advertise     Blog     API     FAQ     Solana     846 Online   Highest 6679       Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 30ms UTC 20:42 PVG 04:42 LAX 13:42 JFK 16:42
    Do have faith in what you're doing.
    ubao msn snddm index pchome yahoo rakuten mypaper meadowduck bidyahoo youbao zxmzxm asda bnvcg cvbfg dfscv mmhjk xxddc yybgb zznbn ccubao uaitu acv GXCV ET GDG YH FG BCVB FJFH CBRE CBC GDG ET54 WRWR RWER WREW WRWER RWER SDG EW SF DSFSF fbbs ubao fhd dfg ewr dg df ewwr ewwr et ruyut utut dfg fgd gdfgt etg dfgt dfgd ert4 gd fgg wr 235 wer3 we vsdf sdf gdf ert xcv sdf rwer hfd dfg cvb rwf afb dfh jgh bmn lgh rty gfds cxv xcv xcs vdas fdf fgd cv sdf tert sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf shasha9178 shasha9178 shasha9178 shasha9178 shasha9178 liflif2 liflif2 liflif2 liflif2 liflif2 liblib3 liblib3 liblib3 liblib3 liblib3 zhazha444 zhazha444 zhazha444 zhazha444 zhazha444 dende5 dende denden denden2 denden21 fenfen9 fenf619 fen619 fenfe9 fe619 sdf sdf sdf sdf sdf zhazh90 zhazh0 zhaa50 zha90 zh590 zho zhoz zhozh zhozho zhozho2 lislis lls95 lili95 lils5 liss9 sdf0ty987 sdft876 sdft9876 sdf09876 sd0t9876 sdf0ty98 sdf0976 sdf0ty986 sdf0ty96 sdf0t76 sdf0876 df0ty98 sf0t876 sd0ty76 sdy76 sdf76 sdf0t76 sdf0ty9 sdf0ty98 sdf0ty987 sdf0ty98 sdf6676 sdf876 sd876 sd876 sdf6 sdf6 sdf9876 sdf0t sdf06 sdf0ty9776 sdf0ty9776 sdf0ty76 sdf8876 sdf0t sd6 sdf06 s688876 sd688 sdf86