SSH Login without password

This scenario explains the login from client machine to server

  • On client run the following command for creating a public key at client end

ssh-keygen -t dsa

  • Copy the public key from client machine to server’s user’s home directory in .ssh

scp $HOME/.ssh/id_dsa.pub user@server:~/.ssh

  • On server run the following command

cat id_dsa.pub >> $HOME/.ssh/authorized_keys

  • If you want the process for both sides run the above commands on server also
  • Now you can securely shell into each other without prompting for password.

2 Responses to SSH Login without password

  1. Sameer Kalra says:

    Good Document. Very Helpful

  2. Abhishek Bhardwaj says:

    Really helpful

Leave a Reply

Your email address will not be published. Required fields are marked *