0
0
  • You must to post comments
0
0

How to setup SSH key authentication in Ubuntu

Step 1 – Create the RSA Key Pair
The first step is to create the key pair on the client machine:

#ssh-keygen

 

You can press enter here, saving the key.

#Enter passphrase (empty for no passphrase):

#Enter passphrase again (empty for no passphrase):
The entire key generation process looks like this:

sshkeygen

Step 2 – Create id_rsa.pub file for public key location

#cat /root/.ssh/id_rsa.pub

sshkey

Step 3 – Copy the public key to remote machine

#ssh-copy-id user@ip_of_remote_machine
#ssh-copy-id splunk@192.168.1.4

And put the remote machine password for adding the key

ssh

Step 4 – Now we login the remote machine without password
#ssh splunk@192.168.1.4

ssh..

Now we got the remote machine without password

  • You must to post comments
Showing 1 result
Your Answer

Please first to submit.