I have Linux console, managed from Windows.

Can login to Linux console from MSTSC service of Windows, as xrdp is installed on Linux.
However I cannot login via Putty with SSH connection. It's displaying error as 'Access denied'.

This error started to occur after I abruptly stopped the execution of rsync operation with Ctrl+C which I started from Putty.

Logging in as user: root
Operating System: Fedora 13

What might have gone wrong?

  • 1
    Have you tried restarting the ssh service on the Linux box? Try sudo service ssh restart
    – terdon
    Feb 20 '14 at 14:24
  • what did you run rsync on? you might have overwritten some configuration (or changed some permissions in the home-directory) that now prevents you from logging in.
    – umläute
    Feb 20 '14 at 14:52
  • @terdon bash: service: command not found Feb 20 '14 at 15:58
  • @umläute I was running rsync to backup mounted directory on same box Feb 20 '14 at 15:58
  • Did you run the service command with sudo? Also try (as root or with sudo) /etc/init.d/ssh restart
    – terdon
    Feb 20 '14 at 15:59

Go in through your MSTSC connection to xrdp and from within there restart your SSH daemon service.

$sudo /etc/init.d/sshd restart


$ sudo service sshd restart

If the problem continues then I'd consult the log file /var/log/secure to see if you can see if it's an authentication issue. You can consult the log file /var/log/messages to confirm that the SSH service is functioning normally as well.


Based on a comment from the OP, "..Failed password for root from port 50677.." it looks like it could be the root user's password isn't what you think. Again using your MSTSC access via xrdp I'd confirm that you can su - and login as root.

If you can then the issue likely lies with either something in your /etc/ssh/sshd_config file not allowing either user root access or the IP you're attempting to connect from might not be allowed access. I would expect different messaging in the /var/log/* log files however, but these are 2 additional leads to follow-up on.

  • I did try your service command but to no avail. and yes /var/log/secure display following messages Feb 20 21:21:36 localhost sshd[31052]: Server listening on port 22. Feb 20 21:21:36 localhost sshd[31052]: Server listening on :: port 22. Feb 20 21:22:39 localhost sshd[31054]: Failed password for root from port 50677 ssh2 Feb 20 21:27:55 localhost sshd[31062]: Failed password for root from port 50699 ssh2 Feb 20 '14 at 15:55
  • @AbhishekMadhani - see updates.
    – slm
    Feb 20 '14 at 16:03

ssh is configured with /etc/ssh/sshd_config it is possible to disable root from login via ssh in there. This question has answers that might help too.

Permit root to login via ssh only with key-based authentication

and this opposite question also provides some answers.

How do I disable remote root login via ssh?


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.