You can provide ssh with a config file if you’re connecting to many different machines with different ports, user names etc.
Create a file called “config” in your .ssh directory on your machine. This file can contain entries such as
Host Home
User chris
Port 8888
HostName chrisonline.comHost Office
User myseriousname
Port 22
HostName machine.atwork.com
What you can do then is just type “ssh Home”and ssh will automatically pick the right user name, machine and port. This is very convenient if you have different user names on different machines. I found this information here.
September 11, 2010 at 4:00 am
thanks, i found it to be helpful
February 9, 2011 at 4:05 pm
[...] http://lookherefirst.wordpress.com/2007/12/17/a-simple-ssh-config-file/ [...]
February 25, 2011 at 3:27 pm
Nice and simple, thanks!
March 28, 2011 at 4:09 am
thank you.great help
April 8, 2011 at 7:04 am
Short and sweet. Thanks!!
April 18, 2011 at 3:45 am
Thank for posting this. Man pages are good reference – list night I needed a quick example to start from. Gotta love SSH – pretty much the best tool in any sys admin toolbox.
November 5, 2011 at 9:51 am
Microsoft 2007 Product Key…
[...]A simple SSH config file « Look here first![...]…
December 1, 2011 at 8:14 pm
[...] Another article by Chris: A Simple SSH Config File [...]
December 27, 2011 at 8:48 pm
web designer and web master…
[...]A simple SSH config file « Look here first![...]…
December 31, 2011 at 6:08 pm
t shirts of funny uk people…
[...]A simple SSH config file « Look here first![...]…
January 3, 2012 at 12:50 am
12HourWesite.com…
[...]A simple SSH config file « Look here first![...]…
January 18, 2012 at 6:04 pm
web design…
[...]A simple SSH config file « Look here first![...]…
April 24, 2012 at 11:57 am
nando pacheco…
[...]A simple SSH config file « Look here first![...]…