Creating an SSH alias

 Posted by at 7:38 pm  Add comments
Oct 202010
 

Are you tied of typing the entire hostname each time you SSH into a machine?

$ ssh -l user01 machine1.example.com

You can add an alias to your ~/.ssh/config file, setting both the username and hostname.

Host mymachine
HostName machine1.example.com
User user01

Now, all you have to type is:

$ ssh mymachine

 Leave a Reply

(required)

(required)

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

   
© 2010 Geektastical Suffusion theme by Sayontan Sinha