Disabling password for sudo in Ubuntu
Disabling the password needed for sudo
for a specific user is very easy in Ubuntu. This method applies to Ubuntu 16.04, but probably also other versions of Ubuntu and maybe even other distros.
First, run the following command:
sudo visudo
Note: If this is the first time you're running this command, you'll most likely be presented with a list of editors to choose from. Choose the one you're most comfortable with.
Then enter the following line at the end of the file:
user ALL=(ALL:ALL) NOPASSWD:ALL
Make sure to replace user with the username of the user you want to allow using sudo
without entering a password.
← Previous
Ludum Dare 39: PowerClick
Next →
Basic server setup (Ubuntu)
Now what?
I’m genuinely thrilled that you’ve made it this far — thank you for reading!
If you’re up for more, here are a few things you can do:
- Reply to this post by email – I’d love to hear from you.
- Subscribe via RSS or email to stay in the loop.
- Reach out on Mastodon – I’m always happy to chat.