linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* loopback behaviour under high load ...
@ 2003-04-02  3:41 Davide Libenzi
  2003-04-02 16:23 ` Davide Libenzi
  0 siblings, 1 reply; 4+ messages in thread
From: Davide Libenzi @ 2003-04-02  3:41 UTC (permalink / raw)
  To: Linux Kernel Mailing List


Ok, this started with a report from an epoll user and I partially followed
the thing. Using the epoll enabled http server+loader and having the
server and the loader hooked through the loopback interface, this user was
looking at connections that occasionally got stuck. The epoll
server+loader are here :

http://www.xmailserver.org/linux-patches/epoll-lib-0.7.tar.gz

and it needs :

http://www.xmailserver.org/libpcl.html

What happened is that under high transaction load, a few connections get
stuck and they complete after a while ( here "a while" ~= 120 sec ). I
initially thought it was an epoll problem, that was losing events. So I
modified the scheduler to call coroutines ( that call read() ) even if no
events were available, and read() indeed returns EAGAIN. In fact, looking
at a netstat output, the data result still inside the output queue of the
sending socket ( write-side write() completed successfully ). The data
remains there even if the load goes to zero, and the stall of those few
connections last for about 120 sec. This happens *only* under very high
load. I coded a very simple echo client+server :

http://www.xmailserver.org/echocs-0.1.tar.gz

using Niels libevent library ( last snapshot ) :

http://www.monkey.org/~provos/libevent/

and it does not happen using this load ( both using poll/select/epoll has
notification API ). This because, while the http load in the first test
tops 30000 transaction/sec on my machine, the echo client+server remains
at no more than 5000 transaction/sec. Also, by putting a micro delay
between the http client connect() and send(), the problem goes away. Very
likely because the load drop significantly. The user that reported me this
behaviour has been able to catch this with tcpdump, and this is his report:

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Hello Davide,

I believe I've pin-pointed the problem.  The problem is that the server is
sending out a second redundant SYN (Synchronize) segment to the client in
response to the client's attempt to write (PUSH) data to the server after
the connection is established:

I ran "tcpdump -i lo" and generated dumps for a good connection and for a
bad connection:



Here is the "tcpdump -i lo" for a GOOD connection
(98% of the connections run this way):
---------------------------------------------------------------------------
Line  1:  11:09:50.893716 localhost.48056 > localhost.webcache: S
3760485494:3760485494(0) win 32767 <mss 16396,sackOK,timestamp 19532466
19520760,nop,wscale 11> (DF)

Line  2:  11:09:50.893839 localhost.webcache > localhost.48056: S
3755548309:3755548309(0) ack 3760485495 win 32767 <mss
16396,sackOK,timestamp 19532467 19532466,nop,wscale 11> (DF)

Line  3:  11:09:50.893924 localhost.48056 > localhost.webcache: . ack 1 win
15 <nop,nop,timestamp 19532467 19532467> (DF)

...
Line  4:  11:09:51.304909 localhost.48056 > localhost.webcache: P 1:6(5) ack
1 win 15 <nop,nop,timestamp 19532878 19532467> (DF)

Line  5:  11:09:51.304955 localhost.webcache > localhost.48056: . ack 6 win
15 <nop,nop,timestamp 19532878 19532878> (DF)

...
Line  6:  11:09:51.470790 localhost.webcache > localhost.48056: P 1:6(5) ack
6 win 15 <nop,nop,timestamp 19533044 19532878> (DF)

Line  7:  11:09:51.470829 localhost.48056 > localhost.webcache: . ack 6 win
15 <nop,nop,timestamp 19533044 19533044> (DF)

...
Line  8:  11:09:51.470895 localhost.webcache > localhost.48056: F 6:6(0) ack
6 win 15 <nop,nop,timestamp 19533044 19533044> (DF)

...
Line  9:  11:09:51.511472 localhost.48056 > localhost.webcache: . ack 7 win
15 <nop,nop,timestamp 19533084 19533044> (DF)

...
Line 10:  11:09:51.611947 localhost.48056 > localhost.webcache: F 6:6(0) ack
7 win 15 <nop,nop,timestamp 19533185 19533044> (DF)

Line 11:  11:09:51.611981 localhost.webcache > localhost.48056: . ack 7 win
15 <nop,nop,timestamp 19533185 19533185> (DF)




Here is the "tcpdump -i lo" for a HUNG connection
(All hung connections run this way):
----------------------------------------------------------------------------
Line  1:  11:09:51.399251 localhost.49186 > localhost.webcache: S
3745756949:3745756949(0) win 32767 <mss 16396,sackOK,timestamp 19532972
19532939,nop,wscale 11> (DF)

Line  2:  11:09:51.399287 localhost.webcache > localhost.49186: S
3755771471:3755771471(0) ack 3745756950 win 32767 <mss
16396,sackOK,timestamp 19532972 19532972,nop,wscale 11> (DF)

Line  3:  11:09:51.399337 localhost.49186 > localhost.webcache: . ack 1 win
15 <nop,nop,timestamp 19532972 19532972> (DF)
...

Line  4:  11:09:51.426500 localhost.49186 > localhost.webcache: P 1:6(5) ack
1 win 15 <nop,nop,timestamp 19532999 19532972> (DF)
...

Line  5:  11:09:54.954548 localhost.webcache > localhost.49186: S
3755771471:3755771471(0) ack 3745756950 win 32767 <mss
16396,sackOK,timestamp 19536528 19532999,nop,wscale 11> (DF)

Line  6:  11:09:54.954641 localhost.49186 > localhost.webcache: . ack 1 win
15 <nop,nop,timestamp 19536528 19536528,nop,nop,sack sack 1 {0:1} > (DF)


*** HERE THERE IS A 120 SECOND DELAY!!!!!
(Line 5 above is in error.  In Line 5 the server is re-transmitting a SYN to
the client (effectively repeating what it did in Line 2).   Compare this
to Line 5 in the "good connection"

So, the client sent

"SYN 3745756949:3745756949(0)" to the server (Line 1),

the server responded correctly with

"SYN 3755771471:3755771471(0) ACK 3745756950" (Line 2),

the client then acknowledged with

"ACK 3755771472" (actually, a normalized "ACK 1") (Line 3).

All of this is as it should be.

At this point, the client has CONNECTed and the server has ACCEPTed.


Now, the client attempts to WRITE by PUSHing 5 bytes:

"P 1:6(5)" (The client is sending the word "Hello") (Line 4).

At this point, the server is SUPPOSED to acknowledge 6 bytes received
via

"ACK 6" (as in Line 5 in the good server connection).

However, instead, the server ERRONEOUSLY responds to the client's PUSH
with a repeat of its SYN -

"S 3755771471:3755771471(0) ack 3745756950".

In other words, it repeats line 2.

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

It seems that the server does not see the client ack at line 3 and it's
trying to resend the SYN ack. But the client saw the initial SYN ack
from the server, that made connect() to return successfully. Running an
ifconfig after a failing run shows no trace of dropped packets (
netdev_max_backlog has been increased to 1000 ) on the user machine :

lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:526602 errors:0 dropped:0 overruns:0 frame:0
          TX packets:526602 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:42045594 (40.0 Mb)  TX bytes:42045594 (40.0 Mb)

To make things short, this is what happens ( on a few connections of the
whole test set ) :

1) Client connect() ... OK
2) Server accept() ... OK
3) Client send request ... OK
4) Server read request ... HUNG for ~120 sec, even if the load last a few
	seconds, then the transaction completes successfully

And netstat shows Recv-Q=0 for the server socket, and Send-Q=N for the
client socket. This has been tested on 2.5.66 vanilla.
I'm running out of options here ...




- Davide


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: loopback behaviour under high load ...
  2003-04-02  3:41 loopback behaviour under high load Davide Libenzi
@ 2003-04-02 16:23 ` Davide Libenzi
  2003-04-02 17:23   ` Martin Josefsson
  0 siblings, 1 reply; 4+ messages in thread
From: Davide Libenzi @ 2003-04-02 16:23 UTC (permalink / raw)
  To: Linux Kernel Mailing List

On Tue, 1 Apr 2003, Davide Libenzi wrote:

> And netstat shows Recv-Q=0 for the server socket, and Send-Q=N for the
> client socket. This has been tested on 2.5.66 vanilla.

An update on this. Kernel 2.4.20+epoll does not have this problem.



- Davide


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: loopback behaviour under high load ...
  2003-04-02 16:23 ` Davide Libenzi
@ 2003-04-02 17:23   ` Martin Josefsson
  2003-04-02 22:47     ` Davide Libenzi
  0 siblings, 1 reply; 4+ messages in thread
From: Martin Josefsson @ 2003-04-02 17:23 UTC (permalink / raw)
  To: Davide Libenzi; +Cc: Linux Kernel Mailing List, netdev

On Wed, 2003-04-02 at 18:23, Davide Libenzi wrote:
> On Tue, 1 Apr 2003, Davide Libenzi wrote:
> 
> > And netstat shows Recv-Q=0 for the server socket, and Send-Q=N for the
> > client socket. This has been tested on 2.5.66 vanilla.
> 
> An update on this. Kernel 2.4.20+epoll does not have this problem.

I see something similar with 2.5.64-bk10 (seen with earlier 2.5 kernels
as well).

I use distcc on my machine which is running 2.5.64-bk10 and using two
remote servers running 2.4.20 to do the compiling.

Sometimes I see a ~120s stall in the middle of a connection with
Recv-Q=0 on the server (2.4.20) and Send-Q=N on the client (2.5.64-bk10)
(it's the client that's sending data to the server)

x.x.x.x = client
y.y.y.y = server

As you can see there's a long delay between 16:02:09 and 16:04:24

There's some packetloss here (probably a congested interface in the
router on the way). The dump was made on the client.

I've included a lot of the dump to give some context.

It appears the 111073:112497(1424) packet at 16:02:09.597800 going to
the server was dropped and the server continues acking the previous
packet. It takes a very long time until the client resends the missing
packet and it appears it's been dropped once again. Then no packets are
sent in either direction until the missing packet is retransmitted after
a 120s timeout and the connection continues.

(I hope there isn't any missing packets in this dump, libpcap without
mmap dropped a lot but with mmap support it said it didn't drop a single
packet)

[snip]
16:02:09.445650 x.x.x.x.57798 > y.y.y.y.3632: . 95409:96833(1424) ack 1 win 730 <nop,nop,timestamp 1466331049 143345355> (DF)
16:02:09.445665 x.x.x.x.57798 > y.y.y.y.3632: P 96833:98257(1424) ack 1 win 730 <nop,nop,timestamp 1466331049 143345355> (DF)
16:02:09.445683 x.x.x.x.57798 > y.y.y.y.3632: . 98257:99681(1424) ack 1 win 730 <nop,nop,timestamp 1466331049 143345355> (DF)
16:02:09.445695 x.x.x.x.57798 > y.y.y.y.3632: . 99681:101105(1424) ack 1 win 730 <nop,nop,timestamp 1466331049 143345355> (DF)
16:02:09.451822 y.y.y.y.3632 > x.x.x.x.57798: . ack 84017 win 64080 <nop,nop,timestamp 143345356 1466331042> (DF)
16:02:09.452573 y.y.y.y.3632 > x.x.x.x.57798: . ack 86865 win 64080 <nop,nop,timestamp 143345356 1466331048> (DF)
16:02:09.452740 y.y.y.y.3632 > x.x.x.x.57798: . ack 89713 win 64080 <nop,nop,timestamp 143345356 1466331048> (DF)
16:02:09.452989 y.y.y.y.3632 > x.x.x.x.57798: . ack 92561 win 64080 <nop,nop,timestamp 143345356 1466331048> (DF)
16:02:09.453352 y.y.y.y.3632 > x.x.x.x.57798: . ack 95409 win 64080 <nop,nop,timestamp 143345356 1466331049> (DF)
16:02:09.454195 y.y.y.y.3632 > x.x.x.x.57798: . ack 98257 win 64080 <nop,nop,timestamp 143345356 1466331049> (DF)
16:02:09.454400 y.y.y.y.3632 > x.x.x.x.57798: . ack 101105 win 64080 <nop,nop,timestamp 143345356 1466331049> (DF)
16:02:09.597688 x.x.x.x.57798 > y.y.y.y.3632: P 101105:102529(1424) ack 1 win 730 <nop,nop,timestamp 1466331201 143345356> (DF)
16:02:09.597702 x.x.x.x.57798 > y.y.y.y.3632: . 102529:103953(1424) ack 1 win 730 <nop,nop,timestamp 1466331201 143345356> (DF)
16:02:09.597721 x.x.x.x.57798 > y.y.y.y.3632: . 103953:105377(1424) ack 1 win 730 <nop,nop,timestamp 1466331201 143345356> (DF)
16:02:09.597734 x.x.x.x.57798 > y.y.y.y.3632: P 105377:106801(1424) ack 1 win 730 <nop,nop,timestamp 1466331201 143345356> (DF)
16:02:09.597755 x.x.x.x.57798 > y.y.y.y.3632: . 106801:108225(1424) ack 1 win 730 <nop,nop,timestamp 1466331201 143345356> (DF)
16:02:09.597768 x.x.x.x.57798 > y.y.y.y.3632: . 108225:109649(1424) ack 1 win 730 <nop,nop,timestamp 1466331201 143345356> (DF)
16:02:09.597787 x.x.x.x.57798 > y.y.y.y.3632: . 109649:111073(1424) ack 1 win 730 <nop,nop,timestamp 1466331201 143345356> (DF)
16:02:09.597800 x.x.x.x.57798 > y.y.y.y.3632: . 111073:112497(1424) ack 1 win 730 <nop,nop,timestamp 1466331201 143345356> (DF)
16:02:09.597818 x.x.x.x.57798 > y.y.y.y.3632: P 112497:113921(1424) ack 1 win 730 <nop,nop,timestamp 1466331201 143345356> (DF)
16:02:09.597832 x.x.x.x.57798 > y.y.y.y.3632: . 113921:115345(1424) ack 1 win 730 <nop,nop,timestamp 1466331201 143345356> (DF)
16:02:09.597849 x.x.x.x.57798 > y.y.y.y.3632: . 115345:116769(1424) ack 1 win 730 <nop,nop,timestamp 1466331201 143345356> (DF)
16:02:09.597862 x.x.x.x.57798 > y.y.y.y.3632: P 116769:118193(1424) ack 1 win 730 <nop,nop,timestamp 1466331201 143345356> (DF)
16:02:09.597903 x.x.x.x.57798 > y.y.y.y.3632: . 118193:119617(1424) ack 1 win 730 <nop,nop,timestamp 1466331201 143345356> (DF)
16:02:09.597915 x.x.x.x.57798 > y.y.y.y.3632: . 119617:121041(1424) ack 1 win 730 <nop,nop,timestamp 1466331201 143345356> (DF)
16:02:09.610011 y.y.y.y.3632 > x.x.x.x.57798: . ack 103953 win 64080 <nop,nop,timestamp 143345372 1466331201> (DF)
16:02:09.610486 y.y.y.y.3632 > x.x.x.x.57798: . ack 106801 win 64080 <nop,nop,timestamp 143345372 1466331201> (DF)
16:02:09.610899 y.y.y.y.3632 > x.x.x.x.57798: . ack 109649 win 64080 <nop,nop,timestamp 143345372 1466331201> (DF)
16:02:09.611921 y.y.y.y.3632 > x.x.x.x.57798: . ack 111073 win 64080 <nop,nop,timestamp 143345372 1466331201,nop,nop,sack sack 1 {113921:115345} > (DF)
16:02:09.611944 y.y.y.y.3632 > x.x.x.x.57798: . ack 111073 win 64080 <nop,nop,timestamp 143345372 1466331201,nop,nop,sack sack 1 {113921:116769} > (DF)
16:02:09.611963 y.y.y.y.3632 > x.x.x.x.57798: . ack 111073 win 64080 <nop,nop,timestamp 143345372 1466331201,nop,nop,sack sack 1 {113921:118193} > (DF)
16:02:09.611996 y.y.y.y.3632 > x.x.x.x.57798: . ack 111073 win 64080 <nop,nop,timestamp 143345372 1466331201,nop,nop,sack sack 1 {113921:119617} > (DF)
16:02:09.703860 x.x.x.x.57798 > y.y.y.y.3632: P 121041:122465(1424) ack 1 win 730 <nop,nop,timestamp 1466331307 143345372> (DF)
16:02:09.703873 x.x.x.x.57798 > y.y.y.y.3632: . 122465:123889(1424) ack 1 win 730 <nop,nop,timestamp 1466331307 143345372> (DF)
16:02:09.703892 x.x.x.x.57798 > y.y.y.y.3632: . 123889:125313(1424) ack 1 win 730 <nop,nop,timestamp 1466331307 143345372> (DF)
16:02:09.703908 x.x.x.x.57798 > y.y.y.y.3632: P 125313:126737(1424) ack 1 win 730 <nop,nop,timestamp 1466331307 143345372> (DF)
16:02:09.703926 x.x.x.x.57798 > y.y.y.y.3632: . 126737:128161(1424) ack 1 win 730 <nop,nop,timestamp 1466331307 143345372> (DF)
16:02:09.703939 x.x.x.x.57798 > y.y.y.y.3632: . 128161:129585(1424) ack 1 win 730 <nop,nop,timestamp 1466331307 143345372> (DF)
16:02:09.705559 x.x.x.x.57798 > y.y.y.y.3632: P 129585:131009(1424) ack 1 win 730 <nop,nop,timestamp 1466331307 143345372> (DF)
16:02:09.705565 x.x.x.x.57798 > y.y.y.y.3632: . 131009:132433(1424) ack 1 win 730 <nop,nop,timestamp 1466331307 143345372> (DF)
16:02:09.705570 x.x.x.x.57798 > y.y.y.y.3632: . 132433:133857(1424) ack 1 win 730 <nop,nop,timestamp 1466331307 143345372> (DF)
16:02:09.705574 x.x.x.x.57798 > y.y.y.y.3632: P 133857:135281(1424) ack 1 win 730 <nop,nop,timestamp 1466331307 143345372> (DF)
16:02:09.705578 x.x.x.x.57798 > y.y.y.y.3632: . 135281:136705(1424) ack 1 win 730 <nop,nop,timestamp 1466331307 143345372> (DF)
16:02:09.714200 y.y.y.y.3632 > x.x.x.x.57798: . ack 111073 win 64080 <nop,nop,timestamp 143345382 1466331201,nop,nop,sack sack 2 {121041:122465}{113921:119617} > (DF)
16:02:09.714499 y.y.y.y.3632 > x.x.x.x.57798: . ack 111073 win 64080 <nop,nop,timestamp 143345382 1466331201,nop,nop,sack sack 2 {121041:123889}{113921:119617} > (DF)
16:02:09.714698 y.y.y.y.3632 > x.x.x.x.57798: . ack 111073 win 64080 <nop,nop,timestamp 143345382 1466331201,nop,nop,sack sack 2 {121041:125313}{113921:119617} > (DF)
16:02:09.714772 y.y.y.y.3632 > x.x.x.x.57798: . ack 111073 win 64080 <nop,nop,timestamp 143345382 1466331201,nop,nop,sack sack 2 {121041:126737}{113921:119617} > (DF)
16:02:09.715358 y.y.y.y.3632 > x.x.x.x.57798: . ack 111073 win 64080 <nop,nop,timestamp 143345382 1466331201,nop,nop,sack sack 2 {121041:128161}{113921:119617} > (DF)
16:02:09.715361 y.y.y.y.3632 > x.x.x.x.57798: . ack 111073 win 64080 <nop,nop,timestamp 143345382 1466331201,nop,nop,sack sack 2 {121041:129585}{113921:119617} > (DF)
16:02:09.715550 y.y.y.y.3632 > x.x.x.x.57798: . ack 111073 win 64080 <nop,nop,timestamp 143345382 1466331201,nop,nop,sack sack 2 {121041:131009}{113921:119617} > (DF)
16:02:09.715552 y.y.y.y.3632 > x.x.x.x.57798: . ack 111073 win 64080 <nop,nop,timestamp 143345382 1466331201,nop,nop,sack sack 2 {121041:132433}{113921:119617} > (DF)
16:02:09.715672 y.y.y.y.3632 > x.x.x.x.57798: . ack 111073 win 64080 <nop,nop,timestamp 143345383 1466331201,nop,nop,sack sack 2 {121041:133857}{113921:119617} > (DF)
16:02:09.715675 y.y.y.y.3632 > x.x.x.x.57798: . ack 111073 win 64080 <nop,nop,timestamp 143345383 1466331201,nop,nop,sack sack 2 {121041:135281}{113921:119617} > (DF)
16:02:09.715677 y.y.y.y.3632 > x.x.x.x.57798: . ack 111073 win 64080 <nop,nop,timestamp 143345383 1466331201,nop,nop,sack sack 2 {121041:136705}{113921:119617} > (DF)
16:02:09.808712 x.x.x.x.57798 > y.y.y.y.3632: . 136705:138129(1424) ack 1 win 730 <nop,nop,timestamp 1466331412 143345382> (DF)
16:02:09.808735 x.x.x.x.57798 > y.y.y.y.3632: P 138129:139548(1419) ack 1 win 730 <nop,nop,timestamp 1466331412 143345382> (DF)
16:02:09.808784 x.x.x.x.57798 > y.y.y.y.3632: . 111073:112497(1424) ack 1 win 730 <nop,nop,timestamp 1466331412 143345382> (DF)
16:02:09.808813 x.x.x.x.57798 > y.y.y.y.3632: P 112497:113921(1424) ack 1 win 730 <nop,nop,timestamp 1466331412 143345382> (DF)
16:02:09.808838 x.x.x.x.57798 > y.y.y.y.3632: . 119617:121041(1424) ack 1 win 730 <nop,nop,timestamp 1466331412 143345383> (DF)
16:02:09.822496 y.y.y.y.3632 > x.x.x.x.57798: . ack 111073 win 64080 <nop,nop,timestamp 143345393 1466331201,nop,nop,sack sack 2 {121041:138129}{113921:119617} > (DF)
16:02:09.822498 y.y.y.y.3632 > x.x.x.x.57798: . ack 111073 win 64080 <nop,nop,timestamp 143345393 1466331201,nop,nop,sack sack 2 {121041:139548}{113921:119617} > (DF)
16:04:24.936079 x.x.x.x.57798 > y.y.y.y.3632: . 111073:112497(1424) ack 1 win 730 <nop,nop,timestamp 1466466560 143345393> (DF)
16:04:24.938582 y.y.y.y.3632 > x.x.x.x.57798: . ack 112497 win 62656 <nop,nop,timestamp 143358906 1466466560,nop,nop,sack sack 2 {121041:139548}{113921:119617} > (DF)
16:04:24.939909 x.x.x.x.57798 > y.y.y.y.3632: P 112497:113921(1424) ack 1 win 730 <nop,nop,timestamp 1466466563 143358906> (DF)
16:04:24.939937 x.x.x.x.57798 > y.y.y.y.3632: . 119617:121041(1424) ack 1 win 730 <nop,nop,timestamp 1466466563 143358906> (DF)
16:04:24.942568 y.y.y.y.3632 > x.x.x.x.57798: . ack 119617 win 55536 <nop,nop,timestamp 143358906 1466466563,nop,nop,sack sack 1 {121041:139548} > (DF)
16:04:24.942573 y.y.y.y.3632 > x.x.x.x.57798: . ack 139548 win 46992 <nop,nop,timestamp 143358906 1466466563> (DF)
16:04:25.038755 y.y.y.y.3632 > x.x.x.x.57798: P 1:1166(1165) ack 139548 win 64080 <nop,nop,timestamp 143358916 1466466563> (DF)
16:04:25.038765 y.y.y.y.3632 > x.x.x.x.57798: F 1166:1166(0) ack 139548 win 64080 <nop,nop,timestamp 143358916 1466466563> (DF)
16:04:25.038893 x.x.x.x.57798 > y.y.y.y.3632: . ack 1166 win 1019 <nop,nop,timestamp 1466466662 143358916> (DF)
16:04:25.039286 x.x.x.x.57798 > y.y.y.y.3632: F 139548:139548(0) ack 1167 win 1019 <nop,nop,timestamp 1466466663 143358916> (DF)
16:04:25.041470 y.y.y.y.3632 > x.x.x.x.57798: . ack 139549 win 64080 <nop,nop,timestamp 143358916 1466466663> (DF)


-- 
/Martin

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: loopback behaviour under high load ...
  2003-04-02 17:23   ` Martin Josefsson
@ 2003-04-02 22:47     ` Davide Libenzi
  0 siblings, 0 replies; 4+ messages in thread
From: Davide Libenzi @ 2003-04-02 22:47 UTC (permalink / raw)
  To: Martin Josefsson; +Cc: Linux Kernel Mailing List, netdev

On Wed, 2 Apr 2003, Martin Josefsson wrote:

> On Wed, 2003-04-02 at 18:23, Davide Libenzi wrote:
> > On Tue, 1 Apr 2003, Davide Libenzi wrote:
> >
> > > And netstat shows Recv-Q=0 for the server socket, and Send-Q=N for the
> > > client socket. This has been tested on 2.5.66 vanilla.
> >
> > An update on this. Kernel 2.4.20+epoll does not have this problem.
>
> I see something similar with 2.5.64-bk10 (seen with earlier 2.5 kernels
> as well).
>
> I use distcc on my machine which is running 2.5.64-bk10 and using two
> remote servers running 2.4.20 to do the compiling.
>
> Sometimes I see a ~120s stall in the middle of a connection with
> Recv-Q=0 on the server (2.4.20) and Send-Q=N on the client (2.5.64-bk10)
> (it's the client that's sending data to the server)
>
> x.x.x.x = client
> y.y.y.y = server
>
> As you can see there's a long delay between 16:02:09 and 16:04:24
>
> There's some packetloss here (probably a congested interface in the
> router on the way). The dump was made on the client.

Hmm, we don't see any dropped packet at interface ( loopback ) level here:

$ cat /proc/net/softnet_stat
002a0c14 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000

$ ifconfig
lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:1349417 errors:0 dropped:0 overruns:0 frame:0
          TX packets:1349417 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0




- Davide


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2003-04-02 22:38 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-04-02  3:41 loopback behaviour under high load Davide Libenzi
2003-04-02 16:23 ` Davide Libenzi
2003-04-02 17:23   ` Martin Josefsson
2003-04-02 22:47     ` Davide Libenzi

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).