1

I have problems ssh to my own box (both remotely or locally) with the message

Permission denied, please try again.

Then I stop the sshd service with /etc/init.d/sshd stop and start sshd in debug mode /usr/sbin/sshd -d. I can connect this time, both remotely or locally works.

I cannot figure out what's the difference between these two situations. Any hints will be highly appreciated. Thank you and best regards!

2
  • The title of your post needs to be a question. How about "Why is SSH permission denied unless sshd is in debug mode?"
    – Mike Brown
    May 31, 2013 at 4:40
  • which disto are you using, and copy how you try your login ssh ...</br> If you are trying to log in ar root@server it won't let you May 31, 2013 at 8:40

2 Answers 2

0

Do you have a password set for your user? If not, you may have to either set a password or use key-based ssh authentication.

1
  • Thank you for your response. I do have a password set for my account. :) May 31, 2013 at 4:31
-1

I had the same problem. Disabling SELinux solved it for me.

You can try to temporary disable SELinux:

echo 0 >/selinux/enforce

or permanent:

#/etc/selinux/config
SELINUX=disabled
1
  • Ehm, this is NOT something you want to do with the possible exception as to debugging the problem. It is akin to "My lock is rusty. Lets solve it by jamming the front door open".
    – Hennes
    Jul 23, 2013 at 13:20

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .