SSH Login without Password
-
In Ubuntu Server 14.04,I having one server and one client .
I am having one user at Server and Client.
I need to login to client from Server without password of the client machine user.
When I try to access the root of the Client,the root password has to be asked for the client machine.
I have tried ssh-keygen but there are some issue came while accessing the root of the client.Why?
What is the processor to do the above mentioned process without any issues at server and client?
-
So you can login without a password? Or you can't? Is it just trying to access different directories that asks for a password? If that is the case you should add yourself to the NOPASSWD group of the sudo file.
-
Try this:
https://www.digitalocean.com/community/tutorials/initial-server-setup-with-ubuntu-14-04
Go to Step Four — Add Public Key Authentication (Recommended)
-
Have you copied your newly created root key from the client to the server?
-
@Reid-Cooper said:
Have you copied your newly created root key from the client to the server?
This! You can create the key but you need to copy it to the target so it also has the key or it won't work. SCP is usually used for this.
-
Was any of that useful?
-
sorry the steps given are useful but the ssh can be able to do for one tmie only after creating the key for the server after that the server ask for password.Why?
-
If the server asks for the password, you haven't set up the keys correctly yet. Have you followed the steps above? Did you copy the key to the server?
-
One of things I routinely have to fix is the permissions on the ~/.ssh/authorized_keys file and the ~/.ssh folder. The former needs to be 600 and the latter needs to be 700. Not sure if that is the same on Ubuntu but I regularly have to do this one CentOS.
-
If this is CentOS you need to either turn off SELinux (probably best here) or reset the permissions again.