How to access WHM panel with Disabled root user
1. First I created a new user and added it to the wheel group
2. I disabled SSH access for the root user by editing /etc/ssh/sshd_config and set PermitRootLogin no, then I restarted SSH service.
3. Then I tried to log into the WHM panel using root user, it failed, then tried with the user added to the wheel group, it also failed.
4. Then I revert the configuration through the user using the terminal and now everything is back to normal.
But my question is, is there a way to block root SSH access and then log into WHM panel?
Also I need to know by disabling root SSH access, will it affect functionality of Cpanel/WHM?
-
root SSH access is disabled in all our servers, and I believe it's a common practise. It does not affect functionality of cPanel/WHM in any way. 0 -
Hello, Disabling direct root logins would not negatively affect the functionality of cPanel/WHM. We even recommend doing this in our What to do if you want to disable direct root logins 0 -
I tried to log into WHM panel: example.com:2087 using the new username (Not root username) but it failed. But I was able to access SSH using the newly created user. But the new user was created using useradd command and it's not a Cpanel account. 0 -
As far as I know only root and cPanel user with reseller privileges can access WHM. Or am I wrong @cPanelWilliam ? 0 -
Hello, @quietFinn is correct, a Linux user added via the useradd command would not have access to WHM. Logging in to WHM with a wheel user shouldn't be necessary since disabling direct root logins would only impact SSH. To clarify, the root user can still log into WHM when you disable direct root logins for SSH. 0
Please sign in to leave a comment.
Comments
5 comments