SSH login using pair of key with no password

In this paper I will present the easiest way to use key pair for loggin to ssh servers. Everything is done in linux operating system.

On client computer we generate our public and private key: course.

ssh-keygen -t rsa -b 4096

Now to use our key for logging we have to upload it to the ssh server. The easiest way is to login using password (last time) by executing following command:

ssh-copy-id YourLogin@server1.vberry.net

server1.vberry.net replace with your server address of course.

One more ssh tip. Following key login is very usefull together with ssh configuration. Go to home folder ~/.ssh and open or create file named config with the following content:

cat ~/.ssh/config
Host s1
 HostName server1.vberry.net
 Port 22
 User YourLogin

With the configuration done as it is explained in this howto now you can login to your server by simply typing: ssh s1.
That’s all folks! Life is beautifull isn’t it ? 😉

Comments are closed.