Enter your email address:

Delivered by FeedBurner

How to login in a remote server using SSH and no password

If you would like to connect to your machine through ssh without being asked for a password you should do this.

  1. Create a public/private key pair
  2. ssh-keygen -t rsa

    Please Do not forget not to write any passphrase, just empty for no passphrase for this to work

  3. Copy te file id_rsa.pub to the $HOME/.ssh directory of the machine you wish to connect to, where $HOME is the directory of the user you would like to connect as. /root/.ssh in the case you would like to connect as root. Consider you would like to connect as the user user
  4. scp $HOME/.ssh/id_rsa.pub usuario@server.remoto:/home/user/.ssh/authorized_keys2

    or

    ssh-copy-id ~/.ssh/id_rsa.pub username@example.com

  5. Now you can connect to the remote server with out being asked for a password.
  6. ssh -l usuario server.remoto

Share/Save
I am assuming that you will by x (not verified)
Hello, After performing the by siva krishna (not verified)

If this was useful for you, please consider making a donation, any amount is welcome, please proceed by clicking on the yellow donate button, thank you in advance.

Navigation

Recent comments