How to switch to root using su on FreeBSD

How can a "normal" user get root rights, or actually switch to root account using the su command when working under FreeBSD?

To do that, that "normal" user needs to be in wheel group. So this command will enable a given user to be able to switch to root account with the command "su – root" or just "su – "

pw groupmod wheel -m [user]

Now that user will be able to become root. This is a good security feature that FreeBSD has, and that I did not know.

 

Credits

Leave a Reply

Your email address will not be published. Required fields are marked *