I have set up sudo
on my FreeBSD server. As I now never want to log in as root anymore, I was wondering whether I should do sudo pw lock root
.
My questions are:
- Is this possible, without forever disabling my machine?
- Is it a smart idea, or is there a good reason to not do this?
- Will I still be able to do
sudo su
to get a root shell?
Best Answer
I actually did this on my FreeBSD box - so yes, it is possible, but of course you should take care to verify that
sudo
works properly before you do so ;-)sudo su
will not work anymore, but you can still dosudo bash
to get a root shell.