Can't connect to Linode with root user via SSH
My Linodes OS: Ubuntu 14.04 LTS
For some reason I can't login to my Linode as the root user, whenever I try to login it always says:
Permission denied (publickey).
But I can still login as my limited user that I setup. I'm only able to login as the root user if I go into /etc/ssh/sshd_config and change PermitRootLogin and PasswordAuthentication to yes. I have followed the "Getting Started with Linode" and "Securing Your Server" guides multiple times. I have also deleted my Linode and created a new one multiple times but nothing seems to work. Any help would be appreciated.
Thanks,
Luke
2 Replies
Just my two cents:
if you set PermitRootLogin to "yes", this will enable you to login as root.
Some people (most) will disable this function, because it is unsecure to allow root login via ssh. as far as i know the getting started guide and securing your server guide tell you to diasble "PermitRootLogin".
So you should disable PermitRootLogin. Every time you connect via ssh, you login as the limited user. when you need to be root, type "sudo". for example: "sudo apt-get install apache". the console will prompt you to enter the root password. so you can execute commands that need root permissions while logged on with your limited user.