How to enable root access on Linux server
Root login over SSH can be required to carry out several operations and allow connection from other servers.
Enable root login over SSH:
1. With root login, edit the file sshd_config file located under /etc/ssh/sshd_config directory with your favorite file editor; vi or nano.
2. Go to the line that says PermitRootLogin yes, and remove the “#” sign in order to comment it out.
3. Now save the file with ‘wq’ if using vi editor or ‘Ctrl + O’ & type ‘Ctrl + X’ to save & exit in nano editor.
4. Finally, restart the SSH server to amend the changes.
You are now ready to connect to the server as root over SSH.