[Novalug] Speed Up Multiple SSH Connections to the Same Server

Paul W. Frields stickster@gmail.com
Fri Jan 2 13:04:08 EST 2009


On Fri, Jan 02, 2009 at 12:55:15PM -0500, Jon LaBadie wrote:
> On Fri, Jan 02, 2009 at 11:42:42AM -0500, Doug Toppin wrote:
> > i tend to do a lot of ssh'ing in different xterms to a few development
> > hosts at work and recently ran across the following tidbit that does
> > make a visible performance difference to me:
> > http://www.linuxjournal.com/content/speed-multiple-ssh-connections-same-server
> > 
> > just passing it along in case anyone else ssh's up a storm as well.
> > 
> 
> I read that bit and wondered.  I'm surprised you see positive results.
> I guess the overhead of individual connections is greater than the
> conflicts that arise when multiple sessions want to use a single
> pipeline.

Most of the overhead is in the initial connection AFAICT, but it is
nice to have instantaneous response! :-)

> Does the master ssh have to remain up for the other sessions to
> continue to function?  Or does something else assume master status
> to keep the link open?

The master must remain up.  If you close it, all other sessions will
die too (yuck).

> If a session hangs in some network access, do all sessions hang?

I haven't seen what happens if the master hangs, but I know that if a
slaved session hangs for some individual reason it doesn't seem to
affect other slaves.  On the other hand, if the delay is due to
something that would logically affect multiple processes on the remote
host, such as heavy swapping, all bets are off.

-- 
Paul W. Frields                                http://paul.frields.org/
  gpg fingerprint: 3DA6 A0AC 6D58 FEC4 0233  5906 ACDB C937 BD11 3717
  http://redhat.com/   -  -  -  -   http://pfrields.fedorapeople.org/
  irc.freenode.net: stickster @ #fedora-docs, #fedora-devel, #fredlug



More information about the Novalug mailing list