Open your favorite text editor and edit /etc/sudoers. Change the following lines to match what is below.
visudo
## Allows people in group wheel to run all commands
%wheel ALL=(ALL) ALL
## Same thing without a password
%wheel ALL=(ALL) NOPASSWD: ALL
Note - I found that you have to uncomment both of the items above, if you are using a gnome desktop. When only the bottom option is set, the the gnome admin apps will not launching, even after you enter the root password in the pop-up. So if you are not using the admin GUI apps then just uncomment the bottom.Next add the user to the wheel group.
usermod -G wheel user
The -G option adds the user to the wheel group. If you use -g instead the sysadmin group will be added as the primary group.
Now your user should be able to use sudo without having to use a password.
Simular pages on this blog:
Use sudo without a password
No comments:
Post a Comment