I have a Debian server, and I can SSH to it.. On SSH there I'm prompted to specify username and pass, I can login here as any user I want..

If I'm root I can change to other users, for example with: "su luxo" to login on user luxo.

But if I'm logged in as another user, I can't login to root, or even other users.. It allways gives an "authentication failure" notify.

How can I solve this? If I want to change user now I have to open a new SSH session every time..

  • If you log in as user are you able to execute su (with no other parameters, typing in the password for the root user, and becoming the root user)? – PP. Jul 25 '13 at 8:47
  • Please paste the output of ls -ld `which su` into your question. – Jenny D Jul 25 '13 at 9:05

As far as I know you can't switch from one user to another via su user - it has to be done as root user. Only way I know to do this as user is via sudo command, so it looks like

sudo su user

If you're able to access root account by doing su or su - (which automatically cd's to root $HOME) everything is ok.

  • 1
    You can use su as a normal user, but you'll be prompted for the new user's password. – Flup Jul 25 '13 at 10:01

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.