Tuesday, 5 July 2011

Add sudo to CentOS

Install the sudo package
# yum install sudo


Edit the sudo file by removing the # from the # %wheel ALL=(ALL) ALL to uncomment it.
# visudo


Save the changes and quit.
:wq


gpasswd -a username wheel

Change to sudo su.
sudo su -

Confirm that you can login with your username, then disable the root login.
passwd -l root

No comments:

Post a Comment

File resolv.conf changed on reboot

The file /etc/resolv.conf was being reset and losing the correct nameserver on my Raspberry Pi after a reboot. The unfriendly way of fixing ...