[Cialug] Cool SSH tricks

Thomas Kula kula at tproa.net
Wed Aug 24 09:34:21 CDT 2011


On Wed, Aug 24, 2011 at 09:07:36AM -0500, Matthew Nuzum wrote:
> 
>    Hey, found this article for some cool SSH tricks.Â
> 
>    [1]http://blogs.perl.org/users/smylers/2011/08/ssh-productivity-tips.h
>    tml
> 
>    I  personally heavily use ~/.ssh/config already but there are a couple
>    I didn't know about. For example the repeated connections and multiple
>    connections  tricks.  Not sure I like the 4 hour thing on the repeated
>    connections  but  15  min would be useful. Seems like I often use this
>    pattern:
>    ssh host
>    ls some-path-where-I-want-a-file
>    exit
>    scp host:some-path-where-i-want-a-file .

I use a bunch of ssh configuration tricks (to the point where I have a
Makefile that generates my .ssh/config....) The jumping through servers
thing is very nice --- we have a lot of hosts here at work where you're
only allowed to ssh into them via a 'console' server. This is *especially*
nice when you have to go through an intermediary server, but need 
port forwarding between your local machine and the end machine. No 
need to make a chain of ssh forwarded ports, it just works.

Also, use screen. Not only is it great for multiple sessions within one
ssh connection, but not worrying about your ssh connection dropping is
great. It's also very handy because I tend to get busy sometimes and
have 17 different terminal windows open to different machines, and 
instead of worrying about closing only the ones I no longer need, I
just quit my terminal program, re-open a connection to the machine
I actually care about, and continue on with life after re-connecting
with screen.

-- 
Thomas L. Kula | kula at tproa.net | http://kula.tproa.net/
Mathom House in Midtown, The People's Republic of Ames


More information about the Cialug mailing list