SSH is commonly used to access and configure remote Linux servers. OpenSSH is a very widely used tool to make SSH connections. On many Linux distributions, root access is disabled by default. However, root access may be enabled on some systems you encounter (especially on the cloud). If it is enabled, it's important to disable it ASAP, as it is a security risk.
Check out the video below to learn how to disable the root login on a Linux system using OpenSSH.
Here's how to do it:
- On the OpenSSH system edit
/etc/ssh/sshd_config
- Find the line that says PermitRootLogin and set it to no.
- Save the configuration.
- Restart the OpenSSH server:
systemctl restart sshd
- Root access should now be denied.
VIDEO
📽️