Bugs #556 and #981 describe situations where TCP_NODELAY is not set. A fix is provided in bug #556. However, the patch commit for packet.c in revision 1.120 does not set TCP_NODELAY for all connections. If the ssh client is invoked with: ssh -N host -R port # TCP_NODELAY is not set ssh -n host -R port sleep 1d # TCP_NODELAY is set - this is a workaround There is a difference in TCP_NODELAY being set or not depending on whether there is a remote command being executed. This is because packet_set_interactive() is only called in do_exec() on the server side. This bug has the unfortunate effect of not setting TCP_NODELAY for port forwarding only connections. The proper fix is probably to use attachment 1099 [details] by Darren Tucker that sets it for all connections on the server side. https://bugzilla.mindrot.org/show_bug.cgi?id=556#c10 https://bugzilla.mindrot.org/attachment.cgi?id=1099&action=diff Issue present is in OpenSSH 4.4 through to 6.2 and -current.
Created attachment 2311 [details] call packet_set_interactive() when -N set I think this is better - it sets the QoS too and uses the presence of a multiplexing socket to infer interactivity.
Thanks for the fix. It fixes the client side socket, which has the issue as well (we worked around it by using -tt flag). With your fix it fixes traffic ssh->sshd. However, TCP_NODELAY is still not set for the TCP socket on sshd's side (for traffic sshd->ssh), which the original attachment 1099 [details] fixes.
fix applied. This will be in openssh-6.3. Thanks!
Set all RESOLVED bugs to CLOSED with release of OpenSSH 7.1