visudo edits the sudoers file in a safe fashion

learn more… | top users | synonyms

1
vote
2answers
293 views

How to change visudo editor from nano to vim? [duplicate]

When I use visudo, it always opens it with nano editor. How to change the editor to vim?
0
votes
0answers
94 views

When running a shell script using sudo I am getting no tty present and no askpass program specified

I am trying to build a project using jenkins. The project is based on node. I wrote a shell script that has only npm install command. I am running the shell script from jenkins as sh ...
4
votes
1answer
125 views

Change the default editor when sudo visudo

When doing sudo visudo, the default editor is nano. I want to change it to vi or vim. I already made vim be the default application to replace gedit upon opening php, plain text, c and h files, by ...
1
vote
2answers
127 views

Auto-starting a GUI application that requires sudo

Question: I need to auto-start a GUI application that requires sudo. I know I need to edit the sudoers file with: sudo visudo However, I don't know what to write in the file. What I already ...
1
vote
1answer
61 views

/etc/sudoers file problem understanding

According to the documentation, modifications of this file may enables local users to execute sudo commands on remote machines: user1 192.168.1.14=(user2:group1) ALL According to what I read, ...
0
votes
0answers
27 views

Get Access Problem as admin user

I want to access "sudoers" file and also access "su -" but I fail and get following error please check terminal output that I have tried. I am m-usman(admin) but not allow to edit or access ? :( ...
0
votes
1answer
449 views

I can't add myself(default user) in sudo group in ubuntu [duplicate]

I accidentally changed my primary group using the following command. sudo usermod -g localgroup shantanu #shantanu is my username I interrupted this process as soon as I realize what is happening. ...
0
votes
0answers
39 views

option `env_reset' does not take a value

This is a problem has bothered me for a long time. When I tried to set proxy for apt-get command, I found a manual in the net. It said that use visudo to edit sudoers file could set proxy for ...
1
vote
1answer
110 views

Changes to sudoers have no effect. Following basic Ubuntu tutorial

I'm following along the Ubuntu sudoers tutorial. Here's my exact /etc/sudoers file (screenshot instead of code block because the formatting was getting messed up). Notice the lines at the bottom ...
0
votes
0answers
26 views

How to avoide log out and log in while editing the sudoers file

I have edited the sudoers file by following the link. So far so good. It say "Log out, and then back in", for sure to see the effects. Is there a way to see the effects with out doing this: "Log ...
1
vote
1answer
1k views

Mount samba share at login using startup script (not fstab)

Background I'm trying to automatically execute a command that mounts a password protected Samba share when my user logs in. The catch is, I share my laptop with another user, and I don't want the ...
0
votes
1answer
67 views

Shutdown launcher withouth password

I added new launcher to panel using this command for shutdown: gksu telinit 0 When I wanted to get rid of constant inserting of password, I did not succeed. I opened visudo and added line "username" ...
1
vote
0answers
28 views

Lost visudo - I seem to have lost visudo, to my great surprise

Lost visudo I seem to have lost visudo, to my great surprise. I'm trying to add to /etc/sudoers or /etc/sudoers.d but when I try and run visudo as root I get this sudo: visudo: command not found ...
1
vote
2answers
672 views

Xubuntu visudo sudoers edit not working

I have been trying to specify a script that I would like to run without being prompted for a password. After a number of google and stack searches and a number of different syntax changes, I still ...
2
votes
3answers
743 views

Run a specific sudo command without a password in Ubuntu 13.10

I would like to run vagrant without being prompted for a password. As this post suggests, I used visudo to add the following line to my sudoers file. john-moz ALL=(ALL) NOPASSWD: /usr/bin/vagrant ...
1
vote
1answer
44 views

Changed suoders to an account that doesn't exist, what should I do

I've installed ubuntu 12.04 with single user, let's call him user1. I then created a new user, let's call him user2. I wanted user2 to be the only user with sudo rights, so I removed all users from ...
0
votes
1answer
50 views

Visudo not working for specified files

I am trying to give sudo ability without the need of passwords to specific files. So far I have: employee ALL=(ALL:ALL) NOPASSWD: /home/file_name The file has a simple chmod command, in the bash ...
0
votes
1answer
107 views

visudo crashing on making changes

I am attempting to add an entry to visudo: admin ALL=(ALL) /bin/kill I have attempted to make changes to this in the past but crashed the visudo file. Can someone assist in telling me where ...
1
vote
3answers
99 views

Do I have to do a new installation?

I was in the /etc/sudoers and might done something wrong, beacuse after I couldn´t use the commandline again. Maybe i deleted sudo in /etc/sudoers. It said something was wrong i line 28. What can I do ...
7
votes
1answer
295 views

How disable mysql command in sudoers file?

How can I disable /usr/bin/mysql command in sudoers file? I've tried to use it this way: %tailonly ALL=!/usr/bin/mysql But when I access user 'tailonly' of group 'tailonly', this command is still ...
2
votes
1answer
258 views

Is there a GUI to `visudo`?

Quite simply, is there a GUI to visudo I can recommend to other users, and use for myself? I have to set up a system where over 50 users have different sudo privileges and I need to juggle them all.
-6
votes
1answer
2k views

How to sudo visudo without a password, remove all prompts for password [closed]

Websites tell me to use sudo when I have no password, usually tell me one of two things. It is bad security Or use 'sudo visudo' and the %admin ALL=(ALL) NOPASSWD: ALL line I would like to not ...
36
votes
3answers
5k views

What are the differences between sudo, su, visudo, chroot, and gksu?

What are the differences between sudo, su, visudo, chroot, and gksu ?
79
votes
12answers
100k views

How to modify a invalid /etc/sudoers file? It throws out an error and not allowing me to edit again

How do I edit an invalid visudo file? Here is what happens: $ sudo visudo >>> /etc/sudoers: syntax error near line 28 <<< sudo: parse error in /etc/sudoers near line 28 sudo: no ...