Step 1 Add your admin user to the ‘wheel’ group so that you will be able to ’su -’ to root, otherwise you may lock yourself out of root.
Adding user to the wheel group.
usermod -g wheel username
Edit /etc/ssh/sshd_config file.
vi /etc/ssh/sshd_config
Next, find the line PermitRootLogin yes and Uncomment it and make it look like PermitRootLogin no
Now restart SSH
/etc/rc.d/init.d/sshd restart
Leave a Reply
You must be logged in to post a comment.