Bug 981 - Flow stop in SSH2
Summary: Flow stop in SSH2
Status: CLOSED FIXED
Alias: None
Product: Portable OpenSSH
Classification: Unclassified
Component: sshd (show other bugs)
Version: 3.9p1
Hardware: ix86 Linux
: P2 normal
Assignee: OpenSSH Bugzilla mailing list
URL:
Keywords:
: 556 (view as bug list)
Depends on:
Blocks: V_4_4
  Show dependency treegraph
 
Reported: 2005-02-04 21:54 AEDT by Jørgen Thomsen
Modified: 2006-09-28 19:25 AEST (History)
1 user (show)

See Also:


Attachments
Set TCP_NODELAY for all connections not just interactive ones (573 bytes, patch)
2005-02-09 20:30 AEDT, Darren Tucker
djm: ok+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Jørgen Thomsen 2005-02-04 21:54:26 AEDT
I very frequently (i.e. nearly every time) experience the following
on Windows XP SP1 using the POP3 program Agent through SSH2 tunneling via PUTTY 
0.56 to fetch mail from a Linux (fedora FC3) box with
OpenSSH_3.9p1, OpenSSL 0.9.7a Feb 19 2003

The stream of data stops, but will resume when entering a CR in the PUTTY 
window.

Example 1:

  000003e0  6e 64 2e 64 6b 2d 68 6f 73 74 6d 61 73 74 65 72  nd.dk-hostmaster
  000003f0  2e 64 6b 20 28 50 6f 73 74 66 69 78 29 20 77 69  .dk (Postfix) wi
  00000400  74 68 20 45 53 4d 54 50                          th ESMTP
Outgoing packet type 93 / 0x5d (SSH2_MSG_CHANNEL_WINDOW_ADJUST)
  00000000  00 00 00 01 00 00 04 00                          ........
Incoming packet type 94 / 0x5e (SSH2_MSG_CHANNEL_DATA)
  00000000  00 00 01 01 00 00 05 a8 0d 0a 09 69 64 20 31 36  ...........id 16
  00000010  33 45 36 43 46 45 35 41 3b 20 46 72 69 2c 20 20  3E6CFE5A; Fri,  
 ......
  00000590  73 76 61 72 65 73 2e 20 0d 0a 20 0d 0a 2a 2a 2a  svares. .. ..***
  000005a0  2a 2a 20 45 6e 67 6c 69 73 68 20 76 65 72 73 69  ** English versi
Outgoing packet type 93 / 0x5d (SSH2_MSG_CHANNEL_WINDOW_ADJUST)
  00000000  00 00 00 01 00 00 05 a8                          ........
stopped here
then entering CR to resume
Outgoing packet type 94 / 0x5e (SSH2_MSG_CHANNEL_DATA)
  00000000  00 00 00 00 00 00 00 01 0d                       .........
Incoming packet type 94 / 0x5e (SSH2_MSG_CHANNEL_DATA)
  00000000  00 00 01 01 00 00 03 23 6f 6e 20 2a 2a 2a 2a 2a  .......#on *****

Example 2:

Event Log: Opening forwarded connection to 80.197.5.166:110
Outgoing packet type 90 / 0x5a (SSH2_MSG_CHANNEL_OPEN)
  00000000  00 00 00 0c 64 69 72 65 63 74 2d 74 63 70 69 70  ....direct-tcpip
  00000010  00 00 01 01 00 00 40 00 00 00 40 00 00 00 00 0c  ......@...@.....
  00000020  38 30 2e 31 39 37 2e 35 2e 31 36 36 00 00 00 6e  80.197.5.166...n
  00000030  00 00 00 16 63 6c 69 65 6e 74 2d 73 69 64 65 2d  ....client-side-
  00000040  63 6f 6e 6e 65 63 74 69 6f 6e 00 00 00 00        connection....
Incoming packet type 91 / 0x5b (SSH2_MSG_CHANNEL_OPEN_CONFIRMATION)
  00000000  00 00 01 01 00 00 00 01 00 02 00 00 00 00 80 00  ................
stopped here
entering CR
Outgoing packet type 94 / 0x5e (SSH2_MSG_CHANNEL_DATA)
  00000000  00 00 00 00 00 00 00 01 0d                       .........
Incoming packet type 94 / 0x5e (SSH2_MSG_CHANNEL_DATA)
  00000000  00 00 01 01 00 00 00 41 2b 4f 4b 20 50 4f 50 33  .......A+OK POP3
  00000010  20 57 65 6c 63 6f 6d 65 20 74 6f 20 47 4e 55 20   Welcome to GNU 
  00000020  50 4f 50 33 20 30 2e 39 2e 39 2d 35 20 3c 32 36  POP3 0.9.9-5 <26
  00000030  34 39 35 2e 31 31 30 37 35 31 32 30 38 34 40 6a  495.1107512084@j
  00000040  74 68 2e 6e 65 74 3e 0d 0a                       th.net>..
Outgoing packet type 93 / 0x5d (SSH2_MSG_CHANNEL_WINDOW_ADJUST)
  00000000  00 00 00 01 00 00 00 41                          .......A
Comment 1 Darren Tucker 2005-02-08 18:56:40 AEDT
Does the window-adjust make it to the server or is it held up in the client (or
network stack)?  Try running the server in debug mode ("/path/to/ssh -ddd") and
check for the adjust messages.
Comment 2 Darren Tucker 2005-02-09 20:30:55 AEDT
Created attachment 811 [details]
Set TCP_NODELAY for all connections not just interactive ones

Does this patch make any difference (from bug #556)?
Comment 3 Jørgen Thomsen 2005-02-10 23:18:52 AEDT
I am observing problem this as I have changed the port forwarding.
The ports were forward to my router IP (external one) which would then route 
the data to the server. This was inefficient, but should not be a problem. Now 
I have changed the IP to the actual server IP were sshd and the other programs 
are running. There seems to be a change in behaviour, so that flow stops are 
less frequent and eventually will recover by itself, but I need more 
observations. 
Comment 4 Damien Miller 2005-05-19 12:51:05 AEST
The patch breaks the dynamic forwarding regress test on OpenBSD. This might be a
bug in nc's SOCKS support rathen than a problem with nodelay though...
Comment 5 Damien Miller 2005-06-21 13:04:51 AEST
The bug in OpenBSD's nc has been fixed - it was no fault of Darren's patch.
Comment 6 Damien Miller 2006-03-12 16:16:22 AEDT
Comment on attachment 811 [details]
Set TCP_NODELAY for all connections not just interactive ones

i think it is time for this patch to go in, ok by me
Comment 7 Darren Tucker 2006-03-13 19:26:24 AEDT
There's also the equivalent patch for sshd (bug #556).
Comment 8 Darren Tucker 2006-03-13 19:28:44 AEDT
*** Bug 556 has been marked as a duplicate of this bug. ***
Comment 9 Darren Tucker 2006-03-13 19:35:15 AEDT
Patch applied and will be in 4.4.  Thanks all.
Comment 10 Darren Tucker 2006-09-28 19:25:32 AEST
With the release of 4.4, we believe that this bug is now closed.  For information about the release please see http://www.openssh.com/txt/release-4.4 .