[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Alex Bochannek: TCP issue.



Has anybody had a chance to look at this problem below? I am starting
to get some heat to replace the system with a Linux box which I would
rather not do. Any ideas how to debug this further?

Thanks.

Alex.




I have observed an interesting problem which is related to TCP. Our
POP/IMAP server (imap-4.6.BETA) works great for everybody here. One
user has been complaining though that when how tries to download large 
messages from home, "it just hangs". Here are some of the parameters
that I think we have been able to establish:

The client machine's configuration is absolutely identical (portable
system)
There is not even a hiccup on the local network but it almost always
happens when connected from home
It seems to happen with messages that are at least a couple 100kB
Other people have seen similar problems when connected from home but
with different sizes (>1MB in one case)
It seems to be related to the slowness of the home link (people on DSL 
do not have the problem)

I ran a ktrace on the ipop3d and it happily keeps writing to the
connection when one write(2) never returns and after ten minutes
(timeout, presumably) the process dies.

The fascinating part is watching the TCP connection. When comparing
the same session on the local network with the home user, the obvious
differences are:

- MSS512
- slower ACKs
- lower TTL

The server keeps sending data (up to the entire length in one case)
but then starts to exponentially back-off from sending even though the
ACK's catch up and the client does not seem to close down the
window. Netstat shows an almost full output queue (16kB) during that
period on that socket and finally the server closes the connection
with an RST. Here's some tcpdump:

14:58:23.059132 server.pop3 > client.1149: . 211087:211599(512) ack 81 win 16384
14:58:23.059536 server.pop3 > client.1149: . 211599:212111(512) ack 81 win 16384
14:58:23.136672 client.1149 > server.pop3: . ack 204943 win 8192 (DF)
14:58:23.137183 server.pop3 > client.1149: . 212111:212623(512) ack 81 win 16384
14:58:23.137585 server.pop3 > client.1149: . 212623:213135(512) ack 81 win 16384
14:58:23.245053 client.1149 > server.pop3: . ack 205967 win 8192 (DF)
14:58:23.245666 server.pop3 > client.1149: . 213135:213647(512) ack 81 win 16384
14:58:23.246130 server.pop3 > client.1149: . 213647:214159(512) ack 81 win 16384
14:58:25.030636 server.pop3 > client.1149: . 205967:206479(512) ack 81 win 16384
14:58:25.337517 client.1149 > server.pop3: . ack 206479 win 8192 (DF)
14:58:29.030456 server.pop3 > client.1149: . 206479:206991(512) ack 81 win 16384
14:58:29.319967 client.1149 > server.pop3: . ack 206991 win 8192 (DF)
14:58:37.030563 server.pop3 > client.1149: . 206991:207503(512) ack 81 win 16384
14:58:37.318121 client.1149 > server.pop3: . ack 207503 win 8192 (DF)
14:58:53.030641 server.pop3 > client.1149: . 207503:208015(512) ack 81 win 16384
14:58:53.314691 client.1149 > server.pop3: . ack 208015 win 8192 (DF)
14:59:25.030609 server.pop3 > client.1149: . 208015:208527(512) ack 81 win 16384
14:59:25.356790 client.1149 > server.pop3: . ack 208527 win 8192 (DF)
15:00:29.030608 server.pop3 > client.1149: . 208527:209039(512) ack 81 win 16384
15:00:29.309781 client.1149 > server.pop3: . ack 209039 win 8192 (DF)
15:01:33.030609 server.pop3 > client.1149: . 209039:209551(512) ack 81 win 16384
15:01:33.400616 client.1149 > server.pop3: . ack 209551 win 8192 (DF)
15:02:37.030586 server.pop3 > client.1149: . 209551:210063(512) ack 81 win 16384
15:02:37.400315 client.1149 > server.pop3: . ack 210063 win 8192 (DF)
15:03:41.030569 server.pop3 > client.1149: . 210063:210575(512) ack 81 win 16384
15:03:41.385951 client.1149 > server.pop3: . ack 210575 win 8192 (DF)
15:04:45.030650 server.pop3 > client.1149: . 210575:211087(512) ack 81 win 16384
15:04:45.387534 client.1149 > server.pop3: . ack 211087 win 8192 (DF)
15:05:49.030767 server.pop3 > client.1149: . 211087:211599(512) ack 81 win 16384
15:05:49.370766 client.1149 > server.pop3: . ack 211599 win 8192 (DF)
15:06:53.030692 server.pop3 > client.1149: . 211599:212111(512) ack 81 win 16384
15:06:53.377596 client.1149 > server.pop3: . ack 212111 win 8192 (DF)
15:07:57.030532 server.pop3 > client.1149: R 212111:212623(512) ack 81 win 0

Any idea what to look at next?

Thanks.

Alex.