# Shutdown Void Linux without password

In Void Linux using just a window manager you don’t have the option to shutdown or reboot the computer without using a password to do it.

The simplest method to give any group of users the ability to shutdown/restart without entering a password and can be useful for simpler WMs, but instead allow users to customize menu actions, such as OpenBox, dmenu and shell scripts. This requires commands be pretended with sudo.

Warning: NEVER edit /etc/sudoers directly! Always use the visudo command.

To allow members of the group “wheel” to shutdown without a password:

sudo visudo

Find this line and add:

%wheel ALL=(ALL) NOPASSWD: /usr/bin/halt, /usr/bin/poweroff, /usr/bin/reboot, /usr/bin/shutdown, /usr/bin/zzz, /usr/bin/ZZZ

Save the file and shutdown or reboot you computer. This will work out of the box.

Home  Linux  Notes  Blog Spot