For some reason I can't login as root into my Mountain Lion 10.8.2.
I've already edited /private/etc/sshd_config
file by removing the comment from
PermitRootLogin yes
and restarted Mac. Still it says "Access denied" when I try to ssh into my Mac.
I also tried going to System Preferences > Sharing > Remote Login and selecting "All users" for "Allow access for" options, but I still get "Access denied". Remote Login is already turned on.
The password I use is a valid sudoing password and is the same one that was used for editing /private/etc/sshd_config
file.
The program from which I'm trying to connect to my Mac is WinSCP, which is basically a file manager, so I can't do any sudoing with it and thus really need to be root in order to have full control over my Mac's files.
Best Answer
Migrated to an answer:
Per Apple:
Which means, unless you have enabled the account and set the password - you probably do not have the
root
user even enabled. Per the link above:Then you can test that it works via SSH and WinSCP.
Shorter Unix way
Open Terminal and run
enter your sudoing password if needed, and then provide the password for the root account when asked.
And don't forget to add "Administrators" to the list of users allowed for remote login.