SyntaxFix
Write A Post
Hire A Developer
Questions
🔍
[sudoers] Exit/save edit to sudoers file? Putty SSH
Home
Question
Exit/save edit to sudoers file? Putty SSH
To make changes to sudo from putty/bash:
Type visudo and press
enter
.
Navigate to the place you wish to edit using the up and down arrow keys.
Press
insert
to go into editing mode.
Make your changes - for example: user ALL=(ALL) ALL.
Note - it matters whether you use tabs or spaces when making changes.
Once your changes are done press
esc
to exit editing mode.
Now type :wq to save and press
enter
.
You should now be back at bash.
Now you can press
ctrl
+
D
to exit the session if you wish.
Examples related to
sudoers
•
Ansible: create a user with sudo privileges
•
Exit/save edit to sudoers file? Putty SSH
•
How to run script as another user without password?