免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 6707 | 回复: 8
打印 上一主题 下一主题

发现 AnyEvent::HTTP proxy 发现一个Bug [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2014-07-29 16:06 |只看该作者 |倒序浏览
本帖最后由 youzhengchuan 于 2014-07-30 12:34 编辑

代码是这样的:

  1. my @proxys = qw(Proxy01 Proxy02 Proxy03 Proxy04 Proxy05);

  2. sub get_content_proxy {
  3.         my $url = shift;
  4.         my $cv = AE::cv;

  5.         foreach my $proxy ( @proxys ) {
  6.                 my $port = "80";
  7.                 ($proxy,$port) = split /:/,$proxy if $proxy =~ /:/;

  8.                 $cv->begin;
  9.                 http_request
  10.                         GET    => "$url?proxyip=$proxy",
  11.                         headers => {"Range" => "bytes=0-1"},
  12.                         timeout => "5",
  13.                         proxy   => [$proxy,$port],
  14.                         sub {
  15.                                 my ($body, $hdr) = @_;
  16.                                 print "http_request $proxy $port $url:\n";
  17.                                 print Dumper $hdr;
  18.                                 if($hdr->{'Status'} == 200){
  19.                                         print $body;
  20.                                 }
  21.                                 print "\n\n";
  22.                                 $cv->end;
  23.                         }
  24.                 ;
  25.         }
  26.         $cv->recv;
  27. }

  28. get_content_proxy("http://www.baidu.com/txt_vod/1.txt")

复制代码
脚本的工作就是轮询每个proxy,依次发请求到每个proxy,然后打印每个proxy响应的头,如果该proxy响应头状态码是200,则打印body。
结果发现AE经常把两个请求发到同一个proxy。
从Dumper打印的头信息看,的确是取到了新的proxy ip地址,但是请求还是发到上一个proxy去,不知道为什么。

下面是tcpdump抓包的结果,发现脚本从来没有发请求到最后一个proxy “Proxy05”,而“Proxy03”收到2次请求,分别在78行和197行。
如下是tcpdump抓包结果:
  1. 15:56:32.638811 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 74: (tos 0x0, ttl 64, id 22079, offset 0, flags [DF], proto TCP (6), length 60)
  2.     172.16.6.140.49535 > Proxy01.80: Flags [S], cksum 0xe899 (correct), seq 737587728, win 5840, options [mss 1460,sackOK,TS val 711517231 ecr 0,nop,wscale 7], length 0
  3.         0x0000:  4500 003c 563f 4000 4006 4a55 ac10 068c  E..<V?@.@.JU....
  4.         0x0010:  de84 0907 c17f 0050 2bf6 b210 0000 0000  .......P+.......
  5.         0x0020:  a002 16d0 e899 0000 0204 05b4 0402 080a  ................
  6.         0x0030:  2a68 e42f 0000 0000 0103 0307            *h./........
  7. 15:56:32.639410 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 74: (tos 0x0, ttl 64, id 8847, offset 0, flags [DF], proto TCP (6), length 60)
  8.     172.16.6.140.58931 > Proxy02.80: Flags [S], cksum 0xae5c (correct), seq 749258431, win 5840, options [mss 1460,sackOK,TS val 711517232 ecr 0,nop,wscale 7], length 0
  9.         0x0000:  4500 003c 228f 4000 4006 7dde ac10 068c  E..<".@.@.}.....
  10.         0x0010:  de84 092e e633 0050 2ca8 c6bf 0000 0000  .....3.P,.......
  11.         0x0020:  a002 16d0 ae5c 0000 0204 05b4 0402 080a  .....\..........
  12.         0x0030:  2a68 e430 0000 0000 0103 0307            *h.0........
  13. 15:56:32.639769 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 74: (tos 0x0, ttl 64, id 58332, offset 0, flags [DF], proto TCP (6), length 60)
  14.     172.16.6.140.36935 > Proxy03.80: Flags [S], cksum 0xc3cd (correct), seq 737544172, win 5840, options [mss 1460,sackOK,TS val 711517232 ecr 0,nop,wscale 7], length 0
  15.         0x0000:  4500 003c e3dc 4000 4006 bc8f ac10 068c  E..<..@.@.......
  16.         0x0010:  de84 092f 9047 0050 2bf6 07ec 0000 0000  .../.G.P+.......
  17.         0x0020:  a002 16d0 c3cd 0000 0204 05b4 0402 080a  ................
  18.         0x0030:  2a68 e430 0000 0000 0103 0307            *h.0........
  19. 15:56:32.640140 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 74: (tos 0x0, ttl 64, id 46471, offset 0, flags [DF], proto TCP (6), length 60)
  20.     172.16.6.140.41889 > Proxy04.80: Flags [S], cksum 0x660a (correct), seq 747852214, win 5840, options [mss 1460,sackOK,TS val 711517233 ecr 0,nop,wscale 7], length 0
  21.         0x0000:  4500 003c b587 4000 4006 eae3 ac10 068c  E..<..@.@.......
  22.         0x0010:  de84 0930 a3a1 0050 2c93 51b6 0000 0000  ...0...P,.Q.....
  23.         0x0020:  a002 16d0 660a 0000 0204 05b4 0402 080a  ....f...........
  24.         0x0030:  2a68 e431 0000 0000 0103 0307            *h.1........
  25. 15:56:32.653442 dc:d2:fc:06:92:68 > 3a:85:4e:40:89:29, ethertype IPv4 (0x0800), length 66: (tos 0x0, ttl 53, id 0, offset 0, flags [DF], proto TCP (6), length 52)
  26.     Proxy01.80 > 172.16.6.140.49535: Flags [S.], cksum 0x12c3 (correct), seq 3570677660, ack 737587729, win 5840, options [mss 1200,nop,nop,sackOK,nop,wscale 9], length 0
  27.         0x0000:  4500 0034 0000 4000 3506 ab9c de84 0907  E..4..@.5.......
  28.         0x0010:  ac10 068c 0050 c17f d4d4 379c 2bf6 b211  .....P....7.+...
  29.         0x0020:  8012 16d0 12c3 0000 0204 04b0 0101 0402  ................
  30.         0x0030:  0103 0309                                ....
  31. 15:56:32.653489 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 54: (tos 0x0, ttl 64, id 22080, offset 0, flags [DF], proto TCP (6), length 40)
  32.     172.16.6.140.49535 > Proxy01.80: Flags [.], cksum 0x6935 (correct), seq 737587729, ack 3570677661, win 46, length 0
  33.         0x0000:  4500 0028 5640 4000 4006 4a68 ac10 068c  E..(V@@.@.Jh....
  34.         0x0010:  de84 0907 c17f 0050 2bf6 b211 d4d4 379d  .......P+.....7.
  35.         0x0020:  5010 002e 6935 0000                      P...i5..
  36. 15:56:32.653870 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 364: (tos 0x0, ttl 64, id 22081, offset 0, flags [DF], proto TCP (6), length 350)
  37.     172.16.6.140.49535 > Proxy01.80: Flags [P.], cksum 0x9b78 (incorrect -> 0xc58e), seq 737587729:737588039, ack 3570677661, win 46, length 310
  38.         0x0000:  4500 015e 5641 4000 4006 4931 ac10 068c  E..^VA@.@.I1....
  39.         0x0010:  de84 0907 c17f 0050 2bf6 b211 d4d4 379d  .......P+.....7.
  40.         0x0020:  5018 002e 9b78 0000 4845 4144 2068 7474  P....x..HEAD.htt
  41.         0x0030:  703a 2f2f 7777 772e 646e 696f 6e2e 636f  p://www.baidu.co
  42.         0x0040:  6d2f 797a 635f 766f 642f 312e 7478 743f  m/txt_vod/1.txt?
  43.         0x0050:  7072 6f78 7969 703d 3232 322e 3133 322e  proxyip=222.132.
  44.         0x0060:  392e 3720 4854 5450 2f31 2e31 0d0a 5573  9.7.HTTP/1.1..Us
  45.         0x0070:  6572 2d61 6765 6e74 3a20 4d6f 7a69 6c6c  er-agent:.Mozill
  46.         0x0080:  612f 352e 3020 2863 6f6d 7061 7469 626c  a/5.0.(compatibl
  47.         0x0090:  653b 2055 3b20 416e 7945 7665 6e74 2d48  e;.U;.AnyEvent-H
  48.         0x00a0:  5454 502f 322e 3231 3b20 2b68 7474 703a  TTP/2.21;.+http:
  49.         0x00b0:  2f2f 736f 6674 7761 7265 2e73 6368 6d6f  //software.schmo
  50.         0x00c0:  7270 2e64 652f 706b 672f 416e 7945 7665  rp.de/pkg/AnyEve
  51.         0x00d0:  6e74 290d 0a43 6f6e 6e65 6374 696f 6e3a  nt)..Connection:
  52.         0x00e0:  2054 650d 0a54 653a 2074 7261 696c 6572  .Te..Te:.trailer
  53.         0x00f0:  730d 0a43 6f6e 7465 6e74 2d6c 656e 6774  s..Content-lengt
  54.         0x0100:  683a 2030 0d0a 5265 6665 7265 723a 2068  h:.0..Referer:.h
  55.         0x0110:  7474 703a 2f2f 7777 772e 646e 696f 6e2e  ttp://www.baidu.
  56.         0x0120:  636f 6d2f 797a 635f 766f 642f 312e 7478  com/txt_vod/1.tx
  57.         0x0130:  743f 7072 6f78 7969 703d 3232 322e 3133  t?proxyip=222.13
  58.         0x0140:  322e 392e 370d 0a48 6f73 743a 2077 7777  2.9.7..Host:.www
  59.         0x0150:  2e64 6e69 6f6e 2e63 6f6d 0d0a 0d0a       .baidu.com....
  60. 15:56:32.655071 dc:d2:fc:06:92:68 > 3a:85:4e:40:89:29, ethertype IPv4 (0x0800), length 66: (tos 0x0, ttl 53, id 0, offset 0, flags [DF], proto TCP (6), length 52)
  61.     Proxy03.80 > 172.16.6.140.36935: Flags [S.], cksum 0xa994 (correct), seq 2142753052, ack 737544173, win 5840, options [mss 1200,nop,nop,sackOK,nop,wscale 9], length 0
  62.         0x0000:  4500 0034 0000 4000 3506 ab74 de84 092f  E..4..@.5..t.../
  63.         0x0010:  ac10 068c 0050 9047 7fb7 d11c 2bf6 07ed  .....P.G....+...
  64.         0x0020:  8012 16d0 a994 0000 0204 04b0 0101 0402  ................
  65.         0x0030:  0103 0309                                ....
  66. 15:56:32.655099 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 54: (tos 0x0, ttl 64, id 58333, offset 0, flags [DF], proto TCP (6), length 40)
  67.     172.16.6.140.36935 > Proxy03.80: Flags [.], cksum 0x0007 (correct), seq 737544173, ack 2142753053, win 46, length 0
  68.         0x0000:  4500 0028 e3dd 4000 4006 bca2 ac10 068c  E..(..@.@.......
  69.         0x0010:  de84 092f 9047 0050 2bf6 07ed 7fb7 d11d  .../.G.P+.......
  70.         0x0020:  5010 002e 0007 0000                      P.......
  71. 15:56:32.655280 dc:d2:fc:06:92:68 > 3a:85:4e:40:89:29, ethertype IPv4 (0x0800), length 66: (tos 0x0, ttl 53, id 0, offset 0, flags [DF], proto TCP (6), length 52)
  72.     Proxy02.80 > 172.16.6.140.58931: Flags [S.], cksum 0xf61f (correct), seq 1482659448, ack 749258432, win 5840, options [mss 1200,nop,nop,sackOK,nop,wscale 9], length 0
  73.         0x0000:  4500 0034 0000 4000 3506 ab75 de84 092e  E..4..@.5..u....
  74.         0x0010:  ac10 068c 0050 e633 585f 9678 2ca8 c6c0  .....P.3X_.x,...
  75.         0x0020:  8012 16d0 f61f 0000 0204 04b0 0101 0402  ................
  76.         0x0030:  0103 0309                                ....
  77. 15:56:32.655285 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 366: (tos 0x0, ttl 64, id 58334, offset 0, flags [DF], proto TCP (6), length 352)
  78.     172.16.6.140.36935 > Proxy03.80: Flags [P.], cksum 0x9ba2 (incorrect -> 0x9fb2), seq 737544173:737544485, ack 2142753053, win 46, length 312
  79.         0x0000:  4500 0160 e3de 4000 4006 bb69 ac10 068c  E..`..@.@..i....
  80.         0x0010:  de84 092f 9047 0050 2bf6 07ed 7fb7 d11d  .../.G.P+.......
  81.         0x0020:  5018 002e 9ba2 0000 4845 4144 2068 7474  P.......HEAD.htt
  82.         0x0030:  703a 2f2f 7777 772e 646e 696f 6e2e 636f  p://www.baidu.co
  83.         0x0040:  6d2f 797a 635f 766f 642f 312e 7478 743f  m/txt_vod/1.txt?
  84.         0x0050:  7072 6f78 7969 703d 3232 322e 3133 322e  proxyip=222.132.
  85.         0x0060:  392e 3437 2048 5454 502f 312e 310d 0a55  9.47.HTTP/1.1..U
  86.         0x0070:  7365 722d 6167 656e 743a 204d 6f7a 696c  ser-agent:.Mozil
  87.         0x0080:  6c61 2f35 2e30 2028 636f 6d70 6174 6962  la/5.0.(compatib
  88.         0x0090:  6c65 3b20 553b 2041 6e79 4576 656e 742d  le;.U;.AnyEvent-
  89.         0x00a0:  4854 5450 2f32 2e32 313b 202b 6874 7470  HTTP/2.21;.+http
  90.         0x00b0:  3a2f 2f73 6f66 7477 6172 652e 7363 686d  ://software.schm
  91.         0x00c0:  6f72 702e 6465 2f70 6b67 2f41 6e79 4576  orp.de/pkg/AnyEv
  92.         0x00d0:  656e 7429 0d0a 436f 6e6e 6563 7469 6f6e  ent)..Connection
  93.         0x00e0:  3a20 5465 0d0a 5465 3a20 7472 6169 6c65  :.Te..Te:.traile
  94.         0x00f0:  7273 0d0a 436f 6e74 656e 742d 6c65 6e67  rs..Content-leng
  95.         0x0100:  7468 3a20 300d 0a52 6566 6572 6572 3a20  th:.0..Referer:.
  96.         0x0110:  6874 7470 3a2f 2f77 7777 2e64 6e69 6f6e  http://www.baidu
  97.         0x0120:  2e63 6f6d 2f79 7a63 5f76 6f64 2f31 2e74  .com/txt_vod/1.t
  98.         0x0130:  7874 3f70 726f 7879 6970 3d32 3232 2e31  xt?proxyip=222.1
  99.         0x0140:  3332 2e39 2e34 370d 0a48 6f73 743a 2077  32.9.47..Host:.w
  100.         0x0150:  7777 2e64 6e69 6f6e 2e63 6f6d 0d0a 0d0a  ww.baidu.com....
  101. 15:56:32.655296 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 54: (tos 0x0, ttl 64, id 8848, offset 0, flags [DF], proto TCP (6), length 40)
  102.     172.16.6.140.58931 > Proxy02.80: Flags [.], cksum 0x4c92 (correct), seq 749258432, ack 1482659449, win 46, length 0
  103.         0x0000:  4500 0028 2290 4000 4006 7df1 ac10 068c  E..(".@.@.}.....
  104.         0x0010:  de84 092e e633 0050 2ca8 c6c0 585f 9679  .....3.P,...X_.y
  105.         0x0020:  5010 002e 4c92 0000                      P...L...
  106. 15:56:32.655581 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 366: (tos 0x0, ttl 64, id 8849, offset 0, flags [DF], proto TCP (6), length 352)
  107.     172.16.6.140.58931 > Proxy02.80: Flags [P.], cksum 0x9ba1 (incorrect -> 0xed3e), seq 749258432:749258744, ack 1482659449, win 46, length 312
  108.         0x0000:  4500 0160 2291 4000 4006 7cb8 ac10 068c  E..`".@.@.|.....
  109.         0x0010:  de84 092e e633 0050 2ca8 c6c0 585f 9679  .....3.P,...X_.y
  110.         0x0020:  5018 002e 9ba1 0000 4845 4144 2068 7474  P.......HEAD.htt
  111.         0x0030:  703a 2f2f 7777 772e 646e 696f 6e2e 636f  p://www.baidu.co
  112.         0x0040:  6d2f 797a 635f 766f 642f 312e 7478 743f  m/txt_vod/1.txt?
  113.         0x0050:  7072 6f78 7969 703d 3232 322e 3133 322e  proxyip=222.132.
  114.         0x0060:  392e 3436 2048 5454 502f 312e 310d 0a55  9.46.HTTP/1.1..U
  115.         0x0070:  7365 722d 6167 656e 743a 204d 6f7a 696c  ser-agent:.Mozil
  116.         0x0080:  6c61 2f35 2e30 2028 636f 6d70 6174 6962  la/5.0.(compatib
  117.         0x0090:  6c65 3b20 553b 2041 6e79 4576 656e 742d  le;.U;.AnyEvent-
  118.         0x00a0:  4854 5450 2f32 2e32 313b 202b 6874 7470  HTTP/2.21;.+http
  119.         0x00b0:  3a2f 2f73 6f66 7477 6172 652e 7363 686d  ://software.schm
  120.         0x00c0:  6f72 702e 6465 2f70 6b67 2f41 6e79 4576  orp.de/pkg/AnyEv
  121.         0x00d0:  656e 7429 0d0a 436f 6e6e 6563 7469 6f6e  ent)..Connection
  122.         0x00e0:  3a20 5465 0d0a 5465 3a20 7472 6169 6c65  :.Te..Te:.traile
  123.         0x00f0:  7273 0d0a 436f 6e74 656e 742d 6c65 6e67  rs..Content-leng
  124.         0x0100:  7468 3a20 300d 0a52 6566 6572 6572 3a20  th:.0..Referer:.
  125.         0x0110:  6874 7470 3a2f 2f77 7777 2e64 6e69 6f6e  http://www.baidu
  126.         0x0120:  2e63 6f6d 2f79 7a63 5f76 6f64 2f31 2e74  .com/txt_vod/1.t
  127.         0x0130:  7874 3f70 726f 7879 6970 3d32 3232 2e31  xt?proxyip=222.1
  128.         0x0140:  3332 2e39 2e34 360d 0a48 6f73 743a 2077  32.9.46..Host:.w
  129.         0x0150:  7777 2e64 6e69 6f6e 2e63 6f6d 0d0a 0d0a  ww.baidu.com....
  130. 15:56:32.656572 dc:d2:fc:06:92:68 > 3a:85:4e:40:89:29, ethertype IPv4 (0x0800), length 66: (tos 0x0, ttl 53, id 0, offset 0, flags [DF], proto TCP (6), length 52)
  131.     Proxy04.80 > 172.16.6.140.41889: Flags [S.], cksum 0x67ba (correct), seq 1457774088, ack 747852215, win 5840, options [mss 1200,nop,nop,sackOK,nop,wscale 9], length 0
  132.         0x0000:  4500 0034 0000 4000 3506 ab73 de84 0930  E..4..@.5..s...0
  133.         0x0010:  ac10 068c 0050 a3a1 56e3 de08 2c93 51b7  .....P..V...,.Q.
  134.         0x0020:  8012 16d0 67ba 0000 0204 04b0 0101 0402  ....g...........
  135.         0x0030:  0103 0309                                ....
  136. 15:56:32.656609 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 54: (tos 0x0, ttl 64, id 46472, offset 0, flags [DF], proto TCP (6), length 40)
  137.     172.16.6.140.41889 > Proxy04.80: Flags [.], cksum 0xbe2c (correct), seq 747852215, ack 1457774089, win 46, length 0
  138.         0x0000:  4500 0028 b588 4000 4006 eaf6 ac10 068c  E..(..@.@.......
  139.         0x0010:  de84 0930 a3a1 0050 2c93 51b7 56e3 de09  ...0...P,.Q.V...
  140.         0x0020:  5010 002e be2c 0000                      P....,..
  141. 15:56:32.656797 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 366: (tos 0x0, ttl 64, id 46473, offset 0, flags [DF], proto TCP (6), length 352)
  142.     172.16.6.140.41889 > Proxy04.80: Flags [P.], cksum 0x9ba3 (incorrect -> 0x5cd7), seq 747852215:747852527, ack 1457774089, win 46, length 312
  143.         0x0000:  4500 0160 b589 4000 4006 e9bd ac10 068c  E..`..@.@.......
  144.         0x0010:  de84 0930 a3a1 0050 2c93 51b7 56e3 de09  ...0...P,.Q.V...
  145.         0x0020:  5018 002e 9ba3 0000 4845 4144 2068 7474  P.......HEAD.htt
  146.         0x0030:  703a 2f2f 7777 772e 646e 696f 6e2e 636f  p://www.baidu.co
  147.         0x0040:  6d2f 797a 635f 766f 642f 312e 7478 743f  m/txt_vod/1.txt?
  148.         0x0050:  7072 6f78 7969 703d 3232 322e 3133 322e  proxyip=222.132.
  149.         0x0060:  392e 3438 2048 5454 502f 312e 310d 0a55  9.48.HTTP/1.1..U
  150.         0x0070:  7365 722d 6167 656e 743a 204d 6f7a 696c  ser-agent:.Mozil
  151.         0x0080:  6c61 2f35 2e30 2028 636f 6d70 6174 6962  la/5.0.(compatib
  152.         0x0090:  6c65 3b20 553b 2041 6e79 4576 656e 742d  le;.U;.AnyEvent-
  153.         0x00a0:  4854 5450 2f32 2e32 313b 202b 6874 7470  HTTP/2.21;.+http
  154.         0x00b0:  3a2f 2f73 6f66 7477 6172 652e 7363 686d  ://software.schm
  155.         0x00c0:  6f72 702e 6465 2f70 6b67 2f41 6e79 4576  orp.de/pkg/AnyEv
  156.         0x00d0:  656e 7429 0d0a 436f 6e6e 6563 7469 6f6e  ent)..Connection
  157.         0x00e0:  3a20 5465 0d0a 5465 3a20 7472 6169 6c65  :.Te..Te:.traile
  158.         0x00f0:  7273 0d0a 436f 6e74 656e 742d 6c65 6e67  rs..Content-leng
  159.         0x0100:  7468 3a20 300d 0a52 6566 6572 6572 3a20  th:.0..Referer:.
  160.         0x0110:  6874 7470 3a2f 2f77 7777 2e64 6e69 6f6e  http://www.baidu
  161.         0x0120:  2e63 6f6d 2f79 7a63 5f76 6f64 2f31 2e74  .com/txt_vod/1.t
  162.         0x0130:  7874 3f70 726f 7879 6970 3d32 3232 2e31  xt?proxyip=222.1
  163.         0x0140:  3332 2e39 2e34 380d 0a48 6f73 743a 2077  32.9.48..Host:.w
  164.         0x0150:  7777 2e64 6e69 6f6e 2e63 6f6d 0d0a 0d0a  ww.baidu.com....
  165. 15:56:32.668530 dc:d2:fc:06:92:68 > 3a:85:4e:40:89:29, ethertype IPv4 (0x0800), length 60: (tos 0x0, ttl 53, id 3270, offset 0, flags [DF], proto TCP (6), length 40)
  166.     Proxy01.80 > 172.16.6.140.49535: Flags [.], cksum 0x681f (correct), seq 3570677661, ack 737588039, win 14, length 0
  167.         0x0000:  4500 0028 0cc6 4000 3506 9ee2 de84 0907  E..(..@.5.......
  168.         0x0010:  ac10 068c 0050 c17f d4d4 379d 2bf6 b347  .....P....7.+..G
  169.         0x0020:  5010 000e 681f 0000 0000 0000 0000       P...h.........
  170. 15:56:32.669574 dc:d2:fc:06:92:68 > 3a:85:4e:40:89:29, ethertype IPv4 (0x0800), length 60: (tos 0x0, ttl 53, id 40960, offset 0, flags [DF], proto TCP (6), length 40)
  171.     Proxy03.80 > 172.16.6.140.36935: Flags [.], cksum 0xfeee (correct), seq 2142753053, ack 737544485, win 14, length 0
  172.         0x0000:  4500 0028 a000 4000 3506 0b80 de84 092f  E..(..@.5....../
  173.         0x0010:  ac10 068c 0050 9047 7fb7 d11d 2bf6 0925  .....P.G....+..%
  174.         0x0020:  5010 000e feee 0000 0000 0000 0000       P.............
  175. 15:56:32.669835 dc:d2:fc:06:92:68 > 3a:85:4e:40:89:29, ethertype IPv4 (0x0800), length 236: (tos 0x0, ttl 53, id 40961, offset 0, flags [DF], proto TCP (6), length 222)
  176.     Proxy03.80 > 172.16.6.140.36935: Flags [P.], cksum 0x33ca (correct), seq 2142753053:2142753235, ack 737544485, win 14, length 182
  177.         0x0000:  4500 00de a001 4000 3506 0ac9 de84 092f  E.....@.5....../
  178.         0x0010:  ac10 068c 0050 9047 7fb7 d11d 2bf6 0925  .....P.G....+..%
  179.         0x0020:  5018 000e 33ca 0000 4854 5450 2f31 2e31  P...3...HTTP/1.1
  180.         0x0030:  2032 3030 204f 4b0d 0a43 6f6e 7465 6e74  .200.OK..Content
  181.         0x0040:  2d54 7970 653a 2061 7070 6c69 6361 7469  -Type:.applicati
  182.         0x0050:  6f6e 2f6f 6374 6574 2d73 7472 6561 6d0d  on/octet-stream.
  183.         0x0060:  0a41 6363 6570 742d 5261 6e67 6573 3a20  .Accept-Ranges:.
  184.         0x0070:  6279 7465 730d 0a43 6f6e 7465 6e74 2d4c  bytes..Content-L
  185.         0x0080:  656e 6774 683a 2031 3232 0d0a 436f 6e6e  ength:.122..Conn
  186.         0x0090:  6563 7469 6f6e 3a20 6b65 6570 2d61 6c69  ection:.keep-ali
  187.         0x00a0:  7665 0d0a 4461 7465 3a20 5475 652c 2032  ve..Date:.Tue,.2
  188.         0x00b0:  3920 4a75 6c20 3230 3134 2030 373a 3536  9.Jul.2014.07:56
  189.         0x00c0:  3a34 3120 474d 540d 0a53 6572 7665 723a  :41.GMT..Server:
  190.         0x00d0:  2064 6e69 6f6e 2d73 7672 0d0a 0d0a       .baidu-svr....
  191. 15:56:32.669843 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 54: (tos 0x0, ttl 64, id 58335, offset 0, flags [DF], proto TCP (6), length 40)
  192.     172.16.6.140.36935 > Proxy03.80: Flags [.], cksum 0xfe10 (correct), seq 737544485, ack 2142753235, win 54, length 0
  193.         0x0000:  4500 0028 e3df 4000 4006 bca0 ac10 068c  E..(..@.@.......
  194.         0x0010:  de84 092f 9047 0050 2bf6 0925 7fb7 d1d3  .../.G.P+..%....
  195.         0x0020:  5010 0036 fe10 0000                      P..6....
  196. 15:56:32.670312 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 366: (tos 0x0, ttl 64, id 58336, offset 0, flags [DF], proto TCP (6), length 352)
  197.     172.16.6.140.36935 > Proxy03.80: Flags [P.], cksum 0x9ba2 (incorrect -> 0x9bba), seq 737544485:737544797, ack 2142753235, win 54, length 312
  198.         0x0000:  4500 0160 e3e0 4000 4006 bb67 ac10 068c  E..`..@.@..g....
  199.         0x0010:  de84 092f 9047 0050 2bf6 0925 7fb7 d1d3  .../.G.P+..%....
  200.         0x0020:  5018 0036 9ba2 0000 4845 4144 2068 7474  P..6....HEAD.htt
  201.         0x0030:  703a 2f2f 7777 772e 646e 696f 6e2e 636f  p://www.baidu.co
  202.         0x0040:  6d2f 797a 635f 766f 642f 312e 7478 743f  m/txt_vod/1.txt?
  203.         0x0050:  7072 6f78 7969 703d 3232 322e 3133 322e  proxyip=222.132.
  204.         0x0060:  392e 3439 2048 5454 502f 312e 310d 0a55  9.49.HTTP/1.1..U
  205.         0x0070:  7365 722d 6167 656e 743a 204d 6f7a 696c  ser-agent:.Mozil
  206.         0x0080:  6c61 2f35 2e30 2028 636f 6d70 6174 6962  la/5.0.(compatib
  207.         0x0090:  6c65 3b20 553b 2041 6e79 4576 656e 742d  le;.U;.AnyEvent-
  208.         0x00a0:  4854 5450 2f32 2e32 313b 202b 6874 7470  HTTP/2.21;.+http
  209.         0x00b0:  3a2f 2f73 6f66 7477 6172 652e 7363 686d  ://software.schm
  210.         0x00c0:  6f72 702e 6465 2f70 6b67 2f41 6e79 4576  orp.de/pkg/AnyEv
  211.         0x00d0:  656e 7429 0d0a 436f 6e6e 6563 7469 6f6e  ent)..Connection
  212.         0x00e0:  3a20 5465 0d0a 5465 3a20 7472 6169 6c65  :.Te..Te:.traile
  213.         0x00f0:  7273 0d0a 436f 6e74 656e 742d 6c65 6e67  rs..Content-leng
  214.         0x0100:  7468 3a20 300d 0a52 6566 6572 6572 3a20  th:.0..Referer:.
  215.         0x0110:  6874 7470 3a2f 2f77 7777 2e64 6e69 6f6e  http://www.baidu
  216.         0x0120:  2e63 6f6d 2f79 7a63 5f76 6f64 2f31 2e74  .com/txt_vod/1.t
  217.         0x0130:  7874 3f70 726f 7879 6970 3d32 3232 2e31  xt?proxyip=222.1
  218.         0x0140:  3332 2e39 2e34 390d 0a48 6f73 743a 2077  32.9.49..Host:.w
  219.         0x0150:  7777 2e64 6e69 6f6e 2e63 6f6d 0d0a 0d0a  ww.baidu.com....
  220. 15:56:32.671223 dc:d2:fc:06:92:68 > 3a:85:4e:40:89:29, ethertype IPv4 (0x0800), length 60: (tos 0x0, ttl 53, id 57989, offset 0, flags [DF], proto TCP (6), length 40)
  221.     Proxy02.80 > 172.16.6.140.58931: Flags [.], cksum 0x4b7a (correct), seq 1482659449, ack 749258744, win 14, length 0
  222.         0x0000:  4500 0028 e285 4000 3506 c8fb de84 092e  E..(..@.5.......
  223.         0x0010:  ac10 068c 0050 e633 585f 9679 2ca8 c7f8  .....P.3X_.y,...
  224.         0x0020:  5010 000e 4b7a 0000 0000 0000 0000       P...Kz........
  225. 15:56:32.672771 dc:d2:fc:06:92:68 > 3a:85:4e:40:89:29, ethertype IPv4 (0x0800), length 60: (tos 0x0, ttl 53, id 19090, offset 0, flags [DF], proto TCP (6), length 40)
  226.     Proxy04.80 > 172.16.6.140.41889: Flags [.], cksum 0xbd14 (correct), seq 1457774089, ack 747852527, win 14, length 0
  227.         0x0000:  4500 0028 4a92 4000 3506 60ed de84 0930  E..(J.@.5.`....0
  228.         0x0010:  ac10 068c 0050 a3a1 56e3 de09 2c93 52ef  .....P..V...,.R.
  229.         0x0020:  5010 000e bd14 0000 0000 0000 0000       P.............
  230. 15:56:32.684736 dc:d2:fc:06:92:68 > 3a:85:4e:40:89:29, ethertype IPv4 (0x0800), length 236: (tos 0x0, ttl 53, id 40962, offset 0, flags [DF], proto TCP (6), length 222)
  231.     Proxy03.80 > 172.16.6.140.36935: Flags [P.], cksum 0x31da (correct), seq 2142753235:2142753417, ack 737544797, win 16, length 182
  232.         0x0000:  4500 00de a002 4000 3506 0ac8 de84 092f  E.....@.5....../
  233.         0x0010:  ac10 068c 0050 9047 7fb7 d1d3 2bf6 0a5d  .....P.G....+..]
  234.         0x0020:  5018 0010 31da 0000 4854 5450 2f31 2e31  P...1...HTTP/1.1
  235.         0x0030:  2032 3030 204f 4b0d 0a43 6f6e 7465 6e74  .200.OK..Content
  236.         0x0040:  2d54 7970 653a 2061 7070 6c69 6361 7469  -Type:.applicati
  237.         0x0050:  6f6e 2f6f 6374 6574 2d73 7472 6561 6d0d  on/octet-stream.
  238.         0x0060:  0a41 6363 6570 742d 5261 6e67 6573 3a20  .Accept-Ranges:.
  239.         0x0070:  6279 7465 730d 0a43 6f6e 7465 6e74 2d4c  bytes..Content-L
  240.         0x0080:  656e 6774 683a 2031 3232 0d0a 436f 6e6e  ength:.122..Conn
  241.         0x0090:  6563 7469 6f6e 3a20 6b65 6570 2d61 6c69  ection:.keep-ali
  242.         0x00a0:  7665 0d0a 4461 7465 3a20 5475 652c 2032  ve..Date:.Tue,.2
  243.         0x00b0:  3920 4a75 6c20 3230 3134 2030 373a 3536  9.Jul.2014.07:56
  244.         0x00c0:  3a34 3120 474d 540d 0a53 6572 7665 723a  :41.GMT..Server:
  245.         0x00d0:  2064 6e69 6f6e 2d73 7672 0d0a 0d0a       .baidu-svr....
  246. 15:56:32.723986 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 54: (tos 0x0, ttl 64, id 58337, offset 0, flags [DF], proto TCP (6), length 40)
  247.     172.16.6.140.36935 > Proxy03.80: Flags [.], cksum 0xfc19 (correct), seq 737544797, ack 2142753417, win 63, length 0
  248.         0x0000:  4500 0028 e3e1 4000 4006 bc9e ac10 068c  E..(..@.@.......
  249.         0x0010:  de84 092f 9047 0050 2bf6 0a5d 7fb7 d289  .../.G.P+..]....
  250.         0x0020:  5010 003f fc19 0000                      P..?....
  251. 15:56:32.734936 dc:d2:fc:06:92:68 > 3a:85:4e:40:89:29, ethertype IPv4 (0x0800), length 187: (tos 0x0, ttl 53, id 57990, offset 0, flags [DF], proto TCP (6), length 173)
  252.     Proxy02.80 > 172.16.6.140.58931: Flags [P.], cksum 0xe39e (correct), seq 1482659449:1482659582, ack 749258744, win 14, length 133
  253.         0x0000:  4500 00ad e286 4000 3506 c875 de84 092e  E.....@.5..u....
  254.         0x0010:  ac10 068c 0050 e633 585f 9679 2ca8 c7f8  .....P.3X_.y,...
  255.         0x0020:  5018 000e e39e 0000 4854 5450 2f31 2e31  P.......HTTP/1.1
  256.         0x0030:  2034 3030 2042 6164 2052 6571 7565 7374  .400.Bad.Request
  257.         0x0040:  0d0a 5374 6174 7573 3a20 3430 3020 4261  ..Status:.400.Ba
  258.         0x0050:  6420 5265 7175 6573 740d 0a43 6f6e 6e65  d.Request..Conne
  259.         0x0060:  6374 696f 6e3a 206b 6565 702d 616c 6976  ction:.keep-aliv
  260.         0x0070:  650d 0a44 6174 653a 2054 7565 2c20 3239  e..Date:.Tue,.29
  261.         0x0080:  204a 756c 2032 3031 3420 3037 3a35 363a  .Jul.2014.07:56:
  262.         0x0090:  3431 2047 4d54 0d0a 5365 7276 6572 3a20  41.GMT..Server:.
  263.         0x00a0:  646e 696f 6e2d 7376 720d 0a0d 0a         baidu-svr....
  264. 15:56:32.734959 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 54: (tos 0x0, ttl 64, id 8850, offset 0, flags [DF], proto TCP (6), length 40)
  265.     172.16.6.140.58931 > Proxy02.80: Flags [.], cksum 0x4acd (correct), seq 749258744, ack 1482659582, win 54, length 0
  266.         0x0000:  4500 0028 2292 4000 4006 7def ac10 068c  E..(".@.@.}.....
  267.         0x0010:  de84 092e e633 0050 2ca8 c7f8 585f 96fe  .....3.P,...X_..
  268.         0x0020:  5010 0036 4acd 0000                      P..6J...
  269. 15:56:32.736554 dc:d2:fc:06:92:68 > 3a:85:4e:40:89:29, ethertype IPv4 (0x0800), length 187: (tos 0x0, ttl 53, id 19091, offset 0, flags [DF], proto TCP (6), length 173)
  270.     Proxy04.80 > 172.16.6.140.41889: Flags [P.], cksum 0x5539 (correct), seq 1457774089:1457774222, ack 747852527, win 14, length 133
  271.         0x0000:  4500 00ad 4a93 4000 3506 6067 de84 0930  E...J.@.5.`g...0
  272.         0x0010:  ac10 068c 0050 a3a1 56e3 de09 2c93 52ef  .....P..V...,.R.
  273.         0x0020:  5018 000e 5539 0000 4854 5450 2f31 2e31  P...U9..HTTP/1.1
  274.         0x0030:  2034 3030 2042 6164 2052 6571 7565 7374  .400.Bad.Request
  275.         0x0040:  0d0a 5374 6174 7573 3a20 3430 3020 4261  ..Status:.400.Ba
  276.         0x0050:  6420 5265 7175 6573 740d 0a43 6f6e 6e65  d.Request..Conne
  277.         0x0060:  6374 696f 6e3a 206b 6565 702d 616c 6976  ction:.keep-aliv
  278.         0x0070:  650d 0a44 6174 653a 2054 7565 2c20 3239  e..Date:.Tue,.29
  279.         0x0080:  204a 756c 2032 3031 3420 3037 3a35 363a  .Jul.2014.07:56:
  280.         0x0090:  3431 2047 4d54 0d0a 5365 7276 6572 3a20  41.GMT..Server:.
  281.         0x00a0:  646e 696f 6e2d 7376 720d 0a0d 0a         baidu-svr....
  282. 15:56:32.736563 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 54: (tos 0x0, ttl 64, id 46474, offset 0, flags [DF], proto TCP (6), length 40)
  283.     172.16.6.140.41889 > Proxy04.80: Flags [.], cksum 0xbc67 (correct), seq 747852527, ack 1457774222, win 54, length 0
  284.         0x0000:  4500 0028 b58a 4000 4006 eaf4 ac10 068c  E..(..@.@.......
  285.         0x0010:  de84 0930 a3a1 0050 2c93 52ef 56e3 de8e  ...0...P,.R.V...
  286.         0x0020:  5010 0036 bc67 0000                      P..6.g..
  287. 15:56:32.746637 dc:d2:fc:06:92:68 > 3a:85:4e:40:89:29, ethertype IPv4 (0x0800), length 187: (tos 0x0, ttl 53, id 3271, offset 0, flags [DF], proto TCP (6), length 173)
  288.     Proxy01.80 > 172.16.6.140.49535: Flags [P.], cksum 0x0044 (correct), seq 3570677661:3570677794, ack 737588039, win 14, length 133
  289.         0x0000:  4500 00ad 0cc7 4000 3506 9e5c de84 0907  E.....@.5..\....
  290.         0x0010:  ac10 068c 0050 c17f d4d4 379d 2bf6 b347  .....P....7.+..G
  291.         0x0020:  5018 000e 0044 0000 4854 5450 2f31 2e31  P....D..HTTP/1.1
  292.         0x0030:  2034 3030 2042 6164 2052 6571 7565 7374  .400.Bad.Request
  293.         0x0040:  0d0a 5374 6174 7573 3a20 3430 3020 4261  ..Status:.400.Ba
  294.         0x0050:  6420 5265 7175 6573 740d 0a43 6f6e 6e65  d.Request..Conne
  295.         0x0060:  6374 696f 6e3a 206b 6565 702d 616c 6976  ction:.keep-aliv
  296.         0x0070:  650d 0a44 6174 653a 2054 7565 2c20 3239  e..Date:.Tue,.29
  297.         0x0080:  204a 756c 2032 3031 3420 3037 3a35 363a  .Jul.2014.07:56:
  298.         0x0090:  3431 2047 4d54 0d0a 5365 7276 6572 3a20  41.GMT..Server:.
  299.         0x00a0:  646e 696f 6e2d 7376 720d 0a0d 0a         baidu-svr....
  300. 15:56:32.746646 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 54: (tos 0x0, ttl 64, id 22082, offset 0, flags [DF], proto TCP (6), length 40)
  301.     172.16.6.140.49535 > Proxy01.80: Flags [.], cksum 0x6772 (correct), seq 737588039, ack 3570677794, win 54, length 0
  302.         0x0000:  4500 0028 5642 4000 4006 4a66 ac10 068c  E..(VB@.@.Jf....
  303.         0x0010:  de84 0907 c17f 0050 2bf6 b347 d4d4 3822  .......P+..G..8"
  304.         0x0020:  5010 0036 6772 0000                      P..6gr..
  305. 15:56:37.435484 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 54: (tos 0x0, ttl 64, id 22083, offset 0, flags [DF], proto TCP (6), length 40)
  306.     172.16.6.140.49535 > Proxy01.80: Flags [F.], cksum 0x6771 (correct), seq 737588039, ack 3570677794, win 54, length 0
  307.         0x0000:  4500 0028 5643 4000 4006 4a65 ac10 068c  E..(VC@.@.Je....
  308.         0x0010:  de84 0907 c17f 0050 2bf6 b347 d4d4 3822  .......P+..G..8"
  309.         0x0020:  5011 0036 6771 0000                      P..6gq..
  310. 15:56:37.435515 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 54: (tos 0x0, ttl 64, id 8851, offset 0, flags [DF], proto TCP (6), length 40)
  311.     172.16.6.140.58931 > Proxy02.80: Flags [F.], cksum 0x4acc (correct), seq 749258744, ack 1482659582, win 54, length 0
  312.         0x0000:  4500 0028 2293 4000 4006 7dee ac10 068c  E..(".@.@.}.....
  313.         0x0010:  de84 092e e633 0050 2ca8 c7f8 585f 96fe  .....3.P,...X_..
  314.         0x0020:  5011 0036 4acc 0000                      P..6J...
  315. 15:56:37.435521 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 54: (tos 0x0, ttl 64, id 58338, offset 0, flags [DF], proto TCP (6), length 40)
  316.     172.16.6.140.36935 > Proxy03.80: Flags [F.], cksum 0xfc18 (correct), seq 737544797, ack 2142753417, win 63, length 0
  317.         0x0000:  4500 0028 e3e2 4000 4006 bc9d ac10 068c  E..(..@.@.......
  318.         0x0010:  de84 092f 9047 0050 2bf6 0a5d 7fb7 d289  .../.G.P+..]....
  319.         0x0020:  5011 003f fc18 0000                      P..?....
  320. 15:56:37.435527 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 54: (tos 0x0, ttl 64, id 46475, offset 0, flags [DF], proto TCP (6), length 40)
  321.     172.16.6.140.41889 > Proxy04.80: Flags [F.], cksum 0xbc66 (correct), seq 747852527, ack 1457774222, win 54, length 0
  322.         0x0000:  4500 0028 b58b 4000 4006 eaf3 ac10 068c  E..(..@.@.......
  323.         0x0010:  de84 0930 a3a1 0050 2c93 52ef 56e3 de8e  ...0...P,.R.V...
  324.         0x0020:  5011 0036 bc66 0000                      P..6.f..
  325. 15:56:37.449707 dc:d2:fc:06:92:68 > 3a:85:4e:40:89:29, ethertype IPv4 (0x0800), length 60: (tos 0x0, ttl 53, id 40963, offset 0, flags [DF], proto TCP (6), length 40)
  326.     Proxy03.80 > 172.16.6.140.36935: Flags [F.], cksum 0xfc46 (correct), seq 2142753417, ack 737544798, win 16, length 0
  327.         0x0000:  4500 0028 a003 4000 3506 0b7d de84 092f  E..(..@.5..}.../
  328.         0x0010:  ac10 068c 0050 9047 7fb7 d289 2bf6 0a5e  .....P.G....+..^
  329.         0x0020:  5011 0010 fc46 0000 0000 0000 0000       P....F........
  330. 15:56:37.449737 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 54: (tos 0x0, ttl 64, id 58339, offset 0, flags [DF], proto TCP (6), length 40)
  331.     172.16.6.140.36935 > Proxy03.80: Flags [.], cksum 0xfc17 (correct), seq 737544798, ack 2142753418, win 63, length 0
  332.         0x0000:  4500 0028 e3e3 4000 4006 bc9c ac10 068c  E..(..@.@.......
  333.         0x0010:  de84 092f 9047 0050 2bf6 0a5e 7fb7 d28a  .../.G.P+..^....
  334.         0x0020:  5010 003f fc17 0000                      P..?....
  335. 15:56:37.450151 dc:d2:fc:06:92:68 > 3a:85:4e:40:89:29, ethertype IPv4 (0x0800), length 60: (tos 0x0, ttl 53, id 3272, offset 0, flags [DF], proto TCP (6), length 40)
  336.     Proxy01.80 > 172.16.6.140.49535: Flags [F.], cksum 0x6798 (correct), seq 3570677794, ack 737588040, win 14, length 0
  337.         0x0000:  4500 0028 0cc8 4000 3506 9ee0 de84 0907  E..(..@.5.......
  338.         0x0010:  ac10 068c 0050 c17f d4d4 3822 2bf6 b348  .....P....8"+..H
  339.         0x0020:  5011 000e 6798 0000 0000 0000 0000       P...g.........
  340. 15:56:37.450167 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 54: (tos 0x0, ttl 64, id 22084, offset 0, flags [DF], proto TCP (6), length 40)
  341.     172.16.6.140.49535 > Proxy01.80: Flags [.], cksum 0x6770 (correct), seq 737588040, ack 3570677795, win 54, length 0
  342.         0x0000:  4500 0028 5644 4000 4006 4a64 ac10 068c  E..(VD@.@.Jd....
  343.         0x0010:  de84 0907 c17f 0050 2bf6 b348 d4d4 3823  .......P+..H..8#
  344.         0x0020:  5010 0036 6770 0000                      P..6gp..
  345. 15:56:37.451210 dc:d2:fc:06:92:68 > 3a:85:4e:40:89:29, ethertype IPv4 (0x0800), length 60: (tos 0x0, ttl 53, id 57991, offset 0, flags [DF], proto TCP (6), length 40)
  346.     Proxy02.80 > 172.16.6.140.58931: Flags [F.], cksum 0x4af3 (correct), seq 1482659582, ack 749258745, win 14, length 0
  347.         0x0000:  4500 0028 e287 4000 3506 c8f9 de84 092e  E..(..@.5.......
  348.         0x0010:  ac10 068c 0050 e633 585f 96fe 2ca8 c7f9  .....P.3X_..,...
  349.         0x0020:  5011 000e 4af3 0000 0000 0000 0000       P...J.........
  350. 15:56:37.451219 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 54: (tos 0x0, ttl 64, id 8852, offset 0, flags [DF], proto TCP (6), length 40)
  351.     172.16.6.140.58931 > Proxy02.80: Flags [.], cksum 0x4acb (correct), seq 749258745, ack 1482659583, win 54, length 0
  352.         0x0000:  4500 0028 2294 4000 4006 7ded ac10 068c  E..(".@.@.}.....
  353.         0x0010:  de84 092e e633 0050 2ca8 c7f9 585f 96ff  .....3.P,...X_..
  354.         0x0020:  5010 0036 4acb 0000                      P..6J...
  355. 15:56:37.451353 dc:d2:fc:06:92:68 > 3a:85:4e:40:89:29, ethertype IPv4 (0x0800), length 60: (tos 0x0, ttl 53, id 19092, offset 0, flags [DF], proto TCP (6), length 40)
  356.     Proxy04.80 > 172.16.6.140.41889: Flags [F.], cksum 0xbc8d (correct), seq 1457774222, ack 747852528, win 14, length 0
  357.         0x0000:  4500 0028 4a94 4000 3506 60eb de84 0930  E..(J.@.5.`....0
  358.         0x0010:  ac10 068c 0050 a3a1 56e3 de8e 2c93 52f0  .....P..V...,.R.
  359.         0x0020:  5011 000e bc8d 0000 0000 0000 0000       P.............
  360. 15:56:37.451365 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 54: (tos 0x0, ttl 64, id 46476, offset 0, flags [DF], proto TCP (6), length 40)
  361.     172.16.6.140.41889 > Proxy04.80: Flags [.], cksum 0xbc65 (correct), seq 747852528, ack 1457774223, win 54, length 0
  362.         0x0000:  4500 0028 b58c 4000 4006 eaf2 ac10 068c  E..(..@.@.......
  363.         0x0010:  de84 0930 a3a1 0050 2c93 52f0 56e3 de8f  ...0...P,.R.V...
  364.         0x0020:  5010 0036 bc65 0000                      P..6.e..
复制代码
另外一个问题,还发现proxy经常返回“595”错误:
'Reason' => 'Connection timed out',
'Status' => 595

但是用curl测试每次都是好的,txt文件内仅仅几个字节的测试内容。

请教大牛帮忙分析看看是什么原因呢。

论坛徽章:
0
2 [报告]
发表于 2014-07-29 16:13 |只看该作者
对于proxy返回595错误的时候,我抓包能看到本机和proxy之间有建立建立的请求,但是不知道是什么原因,连接建立失败了。
下面是Tcpdump抓包的结果:
  1. 16:10:36.303492 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 364: (tos 0x0, ttl 64, id 48869, offset 0, flags [DF], proto TCP (6), length 350)
  2.     172.16.6.140.39282 > Proxy05.80: Flags [P.], cksum 0x9ba2 (incorrect -> 0x2e7c), seq 130773204:130773514, ack 117909953, win 54, length 310
  3.         0x0000:  4500 015e bee5 4000 4006 e062 ac10 068c  E..^..@.@..b....
  4.         0x0010:  de84 0931 9972 0050 07cb 70d4 0707 29c1  ...1.r.P..p...).
  5.         0x0020:  5018 0036 9ba2 0000 4845 4144 2068 7474  P..6....HEAD.htt
  6.         0x0030:  703a 2f2f 7777 772e 646e 696f 6e2e 636f  p://www.baidu.co
  7.         0x0040:  6d2f 797a 635f 766f 642f 312e 7478 743f  m/txt_vod/1.txt?
  8.         0x0050:  7072 6f78 7969 703d 3232 322e 3133 322e  proxyip=222.132.
  9.         0x0060:  392e 3720 4854 5450 2f31 2e31 0d0a 5573  9.7.HTTP/1.1..Us
  10.         0x0070:  6572 2d61 6765 6e74 3a20 4d6f 7a69 6c6c  er-agent:.Mozill
  11.         0x0080:  612f 352e 3020 2863 6f6d 7061 7469 626c  a/5.0.(compatibl
  12.         0x0090:  653b 2055 3b20 416e 7945 7665 6e74 2d48  e;.U;.AnyEvent-H
  13.         0x00a0:  5454 502f 322e 3231 3b20 2b68 7474 703a  TTP/2.21;.+http:
  14.         0x00b0:  2f2f 736f 6674 7761 7265 2e73 6368 6d6f  //software.schmo
  15.         0x00c0:  7270 2e64 652f 706b 672f 416e 7945 7665  rp.de/pkg/AnyEve
  16.         0x00d0:  6e74 290d 0a43 6f6e 6e65 6374 696f 6e3a  nt)..Connection:
  17.         0x00e0:  2054 650d 0a54 653a 2074 7261 696c 6572  .Te..Te:.trailer
  18.         0x00f0:  730d 0a43 6f6e 7465 6e74 2d6c 656e 6774  s..Content-lengt
  19.         0x0100:  683a 2030 0d0a 5265 6665 7265 723a 2068  h:.0..Referer:.h
  20.         0x0110:  7474 703a 2f2f 7777 772e 646e 696f 6e2e  ttp://www.baidu.
  21.         0x0120:  636f 6d2f 797a 635f 766f 642f 312e 7478  com/txt_vod/1.tx
  22.         0x0130:  743f 7072 6f78 7969 703d 3232 322e 3133  t?proxyip=222.13
  23.         0x0140:  322e 392e 370d 0a48 6f73 743a 2077 7777  2.9.7..Host:.www
  24.         0x0150:  2e64 6e69 6f6e 2e63 6f6d 0d0a 0d0a       .baidu.com....
  25. 16:10:36.303950 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 74: (tos 0x0, ttl 64, id 30800, offset 0, flags [DF], proto TCP (6), length 60)
  26.     172.16.6.140.48511 > Proxy02.80: Flags [S], cksum 0xee59 (correct), seq 1089584016, win 5840, options [mss 1460,sackOK,TS val 712360896 ecr 0,nop,wscale 7], length 0
  27.         0x0000:  4500 003c 7850 4000 4006 281d ac10 068c  E..<xP@.@.(.....
  28.         0x0010:  de84 092e bd7f 0050 40f1 bb90 0000 0000  .......P@.......
  29.         0x0020:  a002 16d0 ee59 0000 0204 05b4 0402 080a  .....Y..........
  30.         0x0030:  2a75 c3c0 0000 0000 0103 0307            *u..........
  31. 16:10:36.304260 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 74: (tos 0x0, ttl 64, id 26762, offset 0, flags [DF], proto TCP (6), length 60)
  32.     172.16.6.140.44242 > Proxy03.80: Flags [S], cksum 0x0f91 (correct), seq 1084926795, win 5840, options [mss 1460,sackOK,TS val 712360897 ecr 0,nop,wscale 7], length 0
  33.         0x0000:  4500 003c 688a 4000 4006 37e2 ac10 068c  E..<h.@.@.7.....
  34.         0x0010:  de84 092f acd2 0050 40aa ab4b 0000 0000  .../...P@..K....
  35.         0x0020:  a002 16d0 0f91 0000 0204 05b4 0402 080a  ................
  36.         0x0030:  2a75 c3c1 0000 0000 0103 0307            *u..........
  37. 16:10:36.304514 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 74: (tos 0x0, ttl 64, id 56982, offset 0, flags [DF], proto TCP (6), length 60)
  38.     172.16.6.140.39331 > Proxy04.80: Flags [S], cksum 0xafd5 (correct), seq 1099439447, win 5840, options [mss 1460,sackOK,TS val 712360897 ecr 0,nop,wscale 7], length 0
  39.         0x0000:  4500 003c de96 4000 4006 c1d4 ac10 068c  E..<..@.@.......
  40.         0x0010:  de84 0930 99a3 0050 4188 1d57 0000 0000  ...0...PA..W....
  41.         0x0020:  a002 16d0 afd5 0000 0204 05b4 0402 080a  ................
  42.         0x0030:  2a75 c3c1 0000 0000 0103 0307            *u..........
  43. 16:10:36.304720 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 54: (tos 0x0, ttl 64, id 48870, offset 0, flags [DF], proto TCP (6), length 40)
  44.     172.16.6.140.39282 > Proxy05.80: Flags [F.], cksum 0xd0eb (correct), seq 130773514, ack 117909953, win 54, length 0
  45.         0x0000:  4500 0028 bee6 4000 4006 e197 ac10 068c  E..(..@.@.......
  46.         0x0010:  de84 0931 9972 0050 07cb 720a 0707 29c1  ...1.r.P..r...).
  47.         0x0020:  5011 0036 d0eb 0000                      P..6....
  48. 16:10:36.305013 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 74: (tos 0x0, ttl 64, id 36857, offset 0, flags [DF], proto TCP (6), length 60)
  49.     172.16.6.140.39286 > Proxy05.80: Flags [S], cksum 0x8129 (correct), seq 1098599483, win 5840, options [mss 1460,sackOK,TS val 712360898 ecr 0,nop,wscale 7], length 0
  50.         0x0000:  4500 003c 8ff9 4000 4006 1071 ac10 068c  E..<..@.@..q....
  51.         0x0010:  de84 0931 9976 0050 417b 4c3b 0000 0000  ...1.v.PA{L;....
  52.         0x0020:  a002 16d0 8129 0000 0204 05b4 0402 080a  .....)..........
  53.         0x0030:  2a75 c3c2 0000 0000 0103 0307            *u..........
  54. 16:10:36.318840 dc:d2:fc:06:92:68 > 3a:85:4e:40:89:29, ethertype IPv4 (0x0800), length 66: (tos 0x0, ttl 53, id 0, offset 0, flags [DF], proto TCP (6), length 52)
  55.     Proxy03.80 > 172.16.6.140.44242: Flags [S.], cksum 0x9feb (correct), seq 2491937110, ack 1084926796, win 5840, options [mss 1200,nop,nop,sackOK,nop,wscale 9], length 0
  56.         0x0000:  4500 0034 0000 4000 3506 ab74 de84 092f  E..4..@.5..t.../
  57.         0x0010:  ac10 068c 0050 acd2 9487 f156 40aa ab4c  .....P.....V@..L
  58.         0x0020:  8012 16d0 9feb 0000 0204 04b0 0101 0402  ................
  59.         0x0030:  0103 0309                                ....
  60. 16:10:36.318863 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 54: (tos 0x0, ttl 64, id 0, offset 0, flags [DF], proto TCP (6), length 40)
  61.     172.16.6.140.44242 > Proxy03.80: Flags [R], cksum 0x7c77 (correct), seq 1084926796, win 0, length 0
  62.         0x0000:  4500 0028 0000 4000 4006 a080 ac10 068c  E..(..@.@.......
  63.         0x0010:  de84 092f acd2 0050 40aa ab4c 0000 0000  .../...P@..L....
  64.         0x0020:  5004 0000 7c77 0000                      P...|w..
  65. 16:10:36.319580 dc:d2:fc:06:92:68 > 3a:85:4e:40:89:29, ethertype IPv4 (0x0800), length 66: (tos 0x0, ttl 54, id 0, offset 0, flags [DF], proto TCP (6), length 52)
  66.     Proxy02.80 > 172.16.6.140.48511: Flags [S.], cksum 0xf8b9 (correct), seq 1816174487, ack 1089584017, win 5840, options [mss 1200,nop,nop,sackOK,nop,wscale 9], length 0
  67.         0x0000:  4500 0034 0000 4000 3606 aa75 de84 092e  E..4..@.6..u....
  68.         0x0010:  ac10 068c 0050 bd7f 6c40 9f97 40f1 bb91  .....P..l@..@...
  69.         0x0020:  8012 16d0 f8b9 0000 0204 04b0 0101 0402  ................
  70.         0x0030:  0103 0309                                ....
  71. 16:10:36.319588 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 54: (tos 0x0, ttl 64, id 0, offset 0, flags [DF], proto TCP (6), length 40)
  72.     172.16.6.140.48511 > Proxy02.80: Flags [R], cksum 0x5b3f (correct), seq 1089584017, win 0, length 0
  73.         0x0000:  4500 0028 0000 4000 4006 a081 ac10 068c  E..(..@.@.......
  74.         0x0010:  de84 092e bd7f 0050 40f1 bb91 0000 0000  .......P@.......
  75.         0x0020:  5004 0000 5b3f 0000                      P...[?..
  76. 16:10:36.320716 dc:d2:fc:06:92:68 > 3a:85:4e:40:89:29, ethertype IPv4 (0x0800), length 66: (tos 0x0, ttl 54, id 0, offset 0, flags [DF], proto TCP (6), length 52)
  77.     Proxy04.80 > 172.16.6.140.39331: Flags [S.], cksum 0x7813 (correct), seq 1807409728, ack 1099439448, win 5840, options [mss 1200,nop,nop,sackOK,nop,wscale 9], length 0
  78.         0x0000:  4500 0034 0000 4000 3606 aa73 de84 0930  E..4..@.6..s...0
  79.         0x0010:  ac10 068c 0050 99a3 6bba e240 4188 1d58  .....P..k..@A..X
  80.         0x0020:  8012 16d0 7813 0000 0204 04b0 0101 0402  ....x...........
  81.         0x0030:  0103 0309                                ....
  82. 16:10:36.320723 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 54: (tos 0x0, ttl 64, id 0, offset 0, flags [DF], proto TCP (6), length 40)
  83.     172.16.6.140.39331 > Proxy04.80: Flags [R], cksum 0x1cbc (correct), seq 1099439448, win 0, length 0
  84.         0x0000:  4500 0028 0000 4000 4006 a07f ac10 068c  E..(..@.@.......
  85.         0x0010:  de84 0930 99a3 0050 4188 1d58 0000 0000  ...0...PA..X....
  86.         0x0020:  5004 0000 1cbc 0000                      P.......
  87. 16:10:36.323245 dc:d2:fc:06:92:68 > 3a:85:4e:40:89:29, ethertype IPv4 (0x0800), length 60: (tos 0x0, ttl 53, id 0, offset 0, flags [DF], proto TCP (6), length 40)
  88.     Proxy05.80 > 172.16.6.140.39282: Flags [R], cksum 0x4b04 (correct), seq 117909953, win 0, length 0
  89.         0x0000:  4500 0028 0000 4000 3506 ab7e de84 0931  E..(..@.5..~...1
  90.         0x0010:  ac10 068c 0050 9972 0707 29c1 0000 0000  .....P.r..).....
  91.         0x0020:  5004 0000 4b04 0000 0000 0000 0000       P...K.........
  92. 16:10:36.324130 dc:d2:fc:06:92:68 > 3a:85:4e:40:89:29, ethertype IPv4 (0x0800), length 60: (tos 0x0, ttl 53, id 0, offset 0, flags [DF], proto TCP (6), length 40)
  93.     Proxy05.80 > 172.16.6.140.39282: Flags [R], cksum 0x4b04 (correct), seq 117909953, win 0, length 0
  94.         0x0000:  4500 0028 0000 4000 3506 ab7e de84 0931  E..(..@.5..~...1
  95.         0x0010:  ac10 068c 0050 9972 0707 29c1 0000 0000  .....P.r..).....
  96.         0x0020:  5004 0000 4b04 0000 0000 0000 0000       P...K.........
  97. 16:10:36.324986 dc:d2:fc:06:92:68 > 3a:85:4e:40:89:29, ethertype IPv4 (0x0800), length 66: (tos 0x0, ttl 54, id 0, offset 0, flags [DF], proto TCP (6), length 52)
  98.     Proxy05.80 > 172.16.6.140.39286: Flags [S.], cksum 0xec67 (correct), seq 1070361391, ack 1098599484, win 5840, options [mss 1200,nop,nop,sackOK,nop,wscale 9], length 0
  99.         0x0000:  4500 0034 0000 4000 3606 aa72 de84 0931  E..4..@.6..r...1
  100.         0x0010:  ac10 068c 0050 9976 3fcc 6b2f 417b 4c3c  .....P.v?.k/A{L<
  101.         0x0020:  8012 16d0 ec67 0000 0204 04b0 0101 0402  .....g..........
  102.         0x0030:  0103 0309                                ....
  103. 16:10:36.325027 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 54: (tos 0x0, ttl 64, id 36858, offset 0, flags [DF], proto TCP (6), length 40)
  104.     172.16.6.140.39286 > Proxy05.80: Flags [.], cksum 0x42da (correct), seq 1098599484, ack 1070361392, win 46, length 0
  105.         0x0000:  4500 0028 8ffa 4000 4006 1084 ac10 068c  E..(..@.@.......
  106.         0x0010:  de84 0931 9976 0050 417b 4c3c 3fcc 6b30  ...1.v.PA{L<?.k0
  107.         0x0020:  5010 002e 42da 0000                      P...B...
  108. 16:10:36.325298 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 366: (tos 0x0, ttl 64, id 36859, offset 0, flags [DF], proto TCP (6), length 352)
  109.     172.16.6.140.39286 > Proxy05.80: Flags [P.], cksum 0x9ba4 (incorrect -> 0xe083), seq 1098599484:1098599796, ack 1070361392, win 46, length 312
  110.         0x0000:  4500 0160 8ffb 4000 4006 0f4b ac10 068c  E..`..@.@..K....
  111.         0x0010:  de84 0931 9976 0050 417b 4c3c 3fcc 6b30  ...1.v.PA{L<?.k0
  112.         0x0020:  5018 002e 9ba4 0000 4845 4144 2068 7474  P.......HEAD.htt
  113.         0x0030:  703a 2f2f 7777 772e 646e 696f 6e2e 636f  p://www.baidu.co
  114.         0x0040:  6d2f 797a 635f 766f 642f 312e 7478 743f  m/txt_vod/1.txt?
  115.         0x0050:  7072 6f78 7969 703d 3232 322e 3133 322e  proxyip=222.132.
  116.         0x0060:  392e 3439 2048 5454 502f 312e 310d 0a55  9.49.HTTP/1.1..U
  117.         0x0070:  7365 722d 6167 656e 743a 204d 6f7a 696c  ser-agent:.Mozil
  118.         0x0080:  6c61 2f35 2e30 2028 636f 6d70 6174 6962  la/5.0.(compatib
  119.         0x0090:  6c65 3b20 553b 2041 6e79 4576 656e 742d  le;.U;.AnyEvent-
  120.         0x00a0:  4854 5450 2f32 2e32 313b 202b 6874 7470  HTTP/2.21;.+http
  121.         0x00b0:  3a2f 2f73 6f66 7477 6172 652e 7363 686d  ://software.schm
  122.         0x00c0:  6f72 702e 6465 2f70 6b67 2f41 6e79 4576  orp.de/pkg/AnyEv
  123.         0x00d0:  656e 7429 0d0a 436f 6e6e 6563 7469 6f6e  ent)..Connection
  124.         0x00e0:  3a20 5465 0d0a 5465 3a20 7472 6169 6c65  :.Te..Te:.traile
  125.         0x00f0:  7273 0d0a 436f 6e74 656e 742d 6c65 6e67  rs..Content-leng
  126.         0x0100:  7468 3a20 300d 0a52 6566 6572 6572 3a20  th:.0..Referer:.
  127.         0x0110:  6874 7470 3a2f 2f77 7777 2e64 6e69 6f6e  http://www.baidu
  128.         0x0120:  2e63 6f6d 2f79 7a63 5f76 6f64 2f31 2e74  .com/txt_vod/1.t
  129.         0x0130:  7874 3f70 726f 7879 6970 3d32 3232 2e31  xt?proxyip=222.1
  130.         0x0140:  3332 2e39 2e34 390d 0a48 6f73 743a 2077  32.9.49..Host:.w
  131.         0x0150:  7777 2e64 6e69 6f6e 2e63 6f6d 0d0a 0d0a  ww.baidu.com....
  132. 16:10:36.344393 dc:d2:fc:06:92:68 > 3a:85:4e:40:89:29, ethertype IPv4 (0x0800), length 60: (tos 0x0, ttl 54, id 5506, offset 0, flags [DF], proto TCP (6), length 40)
  133.     Proxy05.80 > 172.16.6.140.39286: Flags [.], cksum 0x41c2 (correct), seq 1070361392, ack 1098599796, win 14, length 0
  134.         0x0000:  4500 0028 1582 4000 3606 94fc de84 0931  E..(..@.6......1
  135.         0x0010:  ac10 068c 0050 9976 3fcc 6b30 417b 4d74  .....P.v?.k0A{Mt
  136.         0x0020:  5010 000e 41c2 0000 0000 0000 0000       P...A.........
  137. 16:10:36.406476 dc:d2:fc:06:92:68 > 3a:85:4e:40:89:29, ethertype IPv4 (0x0800), length 187: (tos 0x0, ttl 54, id 5507, offset 0, flags [DF], proto TCP (6), length 173)
  138.     Proxy05.80 > 172.16.6.140.39286: Flags [P.], cksum 0xdfe5 (correct), seq 1070361392:1070361525, ack 1098599796, win 14, length 133
  139.         0x0000:  4500 00ad 1583 4000 3606 9476 de84 0931  E.....@.6..v...1
  140.         0x0010:  ac10 068c 0050 9976 3fcc 6b30 417b 4d74  .....P.v?.k0A{Mt
  141.         0x0020:  5018 000e dfe5 0000 4854 5450 2f31 2e31  P.......HTTP/1.1
  142.         0x0030:  2034 3030 2042 6164 2052 6571 7565 7374  .400.Bad.Request
  143.         0x0040:  0d0a 5374 6174 7573 3a20 3430 3020 4261  ..Status:.400.Ba
  144.         0x0050:  6420 5265 7175 6573 740d 0a43 6f6e 6e65  d.Request..Conne
  145.         0x0060:  6374 696f 6e3a 206b 6565 702d 616c 6976  ction:.keep-aliv
  146.         0x0070:  650d 0a44 6174 653a 2054 7565 2c20 3239  e..Date:.Tue,.29
  147.         0x0080:  204a 756c 2032 3031 3420 3038 3a31 303a  .Jul.2014.08:10:
  148.         0x0090:  3435 2047 4d54 0d0a 5365 7276 6572 3a20  45.GMT..Server:.
  149.         0x00a0:  646e 696f 6e2d 7376 720d 0a0d 0a         baidu-svr....
  150. 16:10:36.406499 3a:85:4e:40:89:29 > dc:d2:fc:06:92:68, ethertype IPv4 (0x0800), length 54: (tos 0x0, ttl 64, id 36860, offset 0, flags [DF], proto TCP (6), length 40)
  151.     172.16.6.140.39286 > Proxy05.80: Flags [.], cksum 0x4115 (correct), seq 1098599796, ack 1070361525, win 54, length 0
  152.         0x0000:  4500 0028 8ffc 4000 4006 1082 ac10 068c  E..(..@.@.......
  153.         0x0010:  de84 0931 9976 0050 417b 4d74 3fcc 6bb5  ...1.v.PA{Mt?.k.
  154.         0x0020:  5010 0036 4115 0000                      P..6A...
复制代码

论坛徽章:
1
2015年辞旧岁徽章
日期:2015-03-03 16:54:15
3 [报告]
发表于 2014-07-30 09:32 |只看该作者
AnyEvent::HTTP这模块是EV作者本人写的,不太可能出错,所以可以尽量多的考虑自己这边的问题。

我一直用AnyEvent::HTTP的这个proxy,但的确没像你这么用过。

你说“的确是取到了新的proxy ip地址”,那你在第20行做的“print Dumper $hdr;”是否看到了新的proxy ip地址?如果是,那模块本身就应该没问题了。

你的情况,我猜可能是因为你环境原因,包括你说的595的错误。

最后,实在认为是模块本身问题,就发信给作者,作者回复很快的。

论坛徽章:
0
4 [报告]
发表于 2014-07-30 09:48 |只看该作者
回复 3# py


    恩,通过perl打印的信息,的确是看到新的proxy 的ip地址,但是从proxy上的访问日志看,其中一台proxy收到2次请求,但是另外一台却一个请求都没有收到,通过tcpdump抓包确认,perl没有向最后一台proxy建立连接,也没发请求过去。

   但是当proxy数量减少到3个时候,这个问题就不会出现,怀疑是有什么原因导致的。

论坛徽章:
1
2015年辞旧岁徽章
日期:2015-03-03 16:54:15
5 [报告]
发表于 2014-07-30 10:09 |只看该作者
感觉是并发太多造成的,控制一下并发应该就好了

论坛徽章:
0
6 [报告]
发表于 2014-07-30 10:59 |只看该作者
回复 5# py


    我修改了一下代码,去掉了proxy,请求的时候用这种方式:

Get => "http://$cache/$uri?proxyip=$cache",
headers => {"Host" => $host_name,"Range" => "bytes=0-1"},

在这种情况下,就不会出现2个请求发到同一个服务器的情况,但是595、596的错误还是有发生,从测试来看,首次有可能会发生595错误,但是之后就比较少发生,有可能是建立连接的时候timeout太短,但是没找到有设置的地方,所以这个问题还没法确认。

论坛徽章:
0
7 [报告]
发表于 2015-04-22 20:04 |只看该作者
我的是设置了timeout后,建连就 reset

论坛徽章:
0
8 [报告]
发表于 2015-04-26 15:31 |只看该作者
飘零雪 路过 帮 顶一下!!!

求职 : 软件工程师
论坛徽章:
3
程序设计版块每日发帖之星
日期:2015-10-07 06:20:00程序设计版块每日发帖之星
日期:2015-12-13 06:20:00程序设计版块每日发帖之星
日期:2016-05-05 06:20:00
9 [报告]
发表于 2015-04-26 20:51 |只看该作者
发现一个 bug 不是一件小事,尤其是一个稳定运行的模块

1. 这个问题可以重复出现吗?
2. 有简单一些的例子吗?
3. 你的解决建议如何?最好以 patch 的形式提交给作者。

这是一个和真正的大牛建立友谊的机会。
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP