ssh without password

Written By smart| 13 June 2009| 2 Comments

1.Login to the ssh server with your client.

2.Generate ssh key pairs

$ ssh-keygen -t rsa
Generating public/private rsa key pair.
Enter file in which to save the key (/home/username/.ssh/id_rsa):
Enter passphrase (empty for no passphrase):
Enter same passphrase again:
Your identification has been saved in /home/username/.ssh/id_rsa
Your public key has been saved in /home/username/.ssh/id_rsa.pub
$ cd ~/.ssh
$ cat id_rsa.pub >> authorized_keys
$ chmod 600 authorized_keys

#Don’t use any passphrase
Log out of the server and go back to your local shell

$ cd
$ mkdir .ssh

Copy the file id_rsa that was generated on the server into .ssh directory.
$ cd .ssh
$ chmod 600 id_rsa
Now should be able to login with out password

For more reference click on here

Related Posts with Thumbnails

Share With Others

2 Comments »

  • GlenStef said:

    Everything dynamic and very positively! :)

  • sushanth said:

    Thanks for the comment Glenstef

Leave your response!




Comment moderation is enabled. Your comment may take some time to appear.