Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Introduction to Linux - A Hands on Guide
This guide was created as an overview of the Linux Operating System, geared toward new users as an exploration tour and getting started guide, with exercises at the end of each chapter.
For more advanced trainees it can be a desktop reference, and a collection of the base knowledge needed to proceed with system and network administration. This book contains many real life examples derived from the author's experience as a Linux system and network administrator, trainer and consultant. They hope these examples will help you to get a better understanding of the Linux system and that you feel encouraged to try out things on your own.
Click Here to receive this Complete Guide absolutely free.
A while ago I set up two servers so 'root' on the first server could scp to 'root' on the second server without needing a password.
I am now trying to add this functionality for a second (non-root) user on the same pair of servers.
I follow the standard procedure as shown on this site and elsewhere.
As the non-root user I do:
1. Use ssh-keygen rsa to create $HOME/.ssh/id_rsa.pub on first server
2. Copy that file to $HOME/.ssh/authorized_keys for the same user
on the target server.
I have verified that file permissions on the target system are correct and the file and PubKeyAUthentication and RSAAuthenication are set to yes in /etc/ssh/sshd.conf.
No matter what I do I cannot keep the system from asking for a password for the non-root user. The root user continues to work just fine.
Is it not possible to have two password-free ssh users on the same server?
Please use -vvv flag with the ssh and check the sshd logs to find out why this is happening.
I'm curious to see the logs as well. I remember this problem a few years ago, I had a non-root user, but I was able to setup passwordless ssh/scp to another machine where I landed as root. If I remember, as long as I had the correct (non-root) RSA key in my '/root/.ssh/authorized_keys' on the machine I wanted to connect to as root... it worked.
ssh-keygen -t rsa
cat $HOME/.ssh/id_rsa.pub (copy)
vi /root/.ssh/authorized_keys (paste)
Don't remember if I had to do authorized_keys or authorized_keys2, and there are better ways to copy/paste, but you get the idea....