Questions related to the sudo command that allows users to run programs with the privileges of a different user (normally the root user).

learn more… | top users | synonyms (1)

2
votes
1answer
7k views

How to uninstall Ubuntu Software Center in 11.10? [duplicate]

I am trying to uninstall software center for ubuntu oneric using the command sudo apt-get remove software center and get this as result Reading package lists... Done Building dependency tree ...
4
votes
1answer
5k views

/etc/environment and /etc/profile.d/* ignored for the root user [duplicate]

How do I set global environment variables in Ubuntu, in such a way, that they would apply also to root user? Setting PATH or JAVA_HOME in /etc/environment or in /etc/profile.d/my_settings.sh both ...
4
votes
2answers
2k views

Allow user to execute sudo commands

I've looked at Add user to "sudo" group and added user (say 'abc') to sudo group But now when user 'abc' tries to use sudo commands ubuntu says, 'abc' is not in sudoers list, this incident ...
2
votes
2answers
860 views

enable auto-completion of apt-get for non-privileged user?

I've enabled apt-get in SUDO without password , and bash autocompletion for it need to be enabled as well , but how ? If i try to source that file: %> . /etc/bash_completion.d/apt No command ...
1
vote
4answers
5k views

Sudoers permission without loging in as root

I am a new user to Ubuntu 10.10 My problem is when I start my machine it takes me to login screen of Ubuntu but I didn't get option for logging in as user or root I know my root password and all even ...
0
votes
2answers
228 views

How do I switch default root authorization app?

Somehow I've messed everything up and when I open a program like time-admin and click "Click to make changes", it uses a Qt / KDE style interface rather than the Gtk style. Running gksudo ...
1
vote
2answers
743 views

How do I get Unity to launch “Log File Viewer” as root?

By default, "Log File Viewer" is not launched from Unity as root in Ubuntu 11.04. This is pretty useless, as most of the log files are only readable by root. How can I change this behavior so that it ...
7
votes
1answer
259 views

Why superuser don't have global menu integration? [closed]

In Unity, when running an application as a superuser, the menu is in the old-style. It's not integrated in the global menu. Why?
2
votes
3answers
600 views

how to recover from mounting /usr/ nosuid

I was able to move /usrto an external harddrive. In fstab I mistakenly mounted the drive with nosuid. Now I can't use sudo or su. I can't edit the fstab entry. When I manage to open it I can't do so ...
85
votes
10answers
102k views

Error message when I run sudo: unable to resolve host (none)

I have this issue on AWS on some servers. Whenever I run sudo the terminal is stuck doing seemingly nothing, until it finally spits out this error message. My terminal looks like this: ...
5
votes
1answer
3k views

I accidentally removed myself from sudoers, how can I fix this? [duplicate]

I have one admin account and recently I have accidentally added myself to a single group (usermod -G without -a). So, I am not in the sudoers file any more. However, it is not possible to log in to ...
1
vote
2answers
3k views

Add user that can read / write a root, www-data files

How can I do that? I got user amira on my Ubuntu 11.4, I want him to able to see / read / write a root user files such as /etc/* and apache files
12
votes
1answer
16k views

What exactly does sudo apt-get -f install do?

I have seen it before. I am just wondering what exactly does it do?
1
vote
2answers
296 views

sudo, su problems [duplicate]

During the installation process I was asked to set a password. I chose a password (a strong one) and everything goes smoothly every time I log in. Problems arise whenever I resort to "sudo" or "su" ...
11
votes
2answers
17k views

Environment variables when run with 'sudo'

As example to my question, my ~/.bashrc file contains this lines: > export LD_LIBRARY_PATH=/opt/intel/mkl/lib/ia32:$LD_LIBRARY_PATH > export LD_PRELOAD=/opt/intel/mkl/lib/ia32/libmkl_core.so ...
2
votes
1answer
306 views

why is access denied when I run hwinfo

I recently had someone install ubuntu on my laptop and something just doesn't feel right about it. I am a newbie and don't really know what I'm looking for or how to look for it. after trying to make ...
3
votes
3answers
162 views

Will my windows partition be affected if I re-install Ubuntu?

I am new to Ubuntu. I recently changed all permissions of the /etc directory in order to edit the hosts file. After that, I realized it was a big mistake. I'm also running Ubuntu along side windows7 ...
3
votes
1answer
677 views

Why does a command work from shell, but not from the applications menu?

I'm trying to add a command to my applications menu: But when I select it from the applications menu, it doesn't do anything. When I run that same command from the shell, however, it runs fine. ...
1
vote
1answer
614 views

ddclient not working without sudo

When I run ddclient (DynamicDns Updator) without sudo, I get WARNING: file /etc/ddclient.conf: Cannot open file '/etc/ddclient.conf'. (Permission denied) stat() on closed filehandle FD at ...
10
votes
3answers
25k views

Mount VirtualBox SharedFolder in Ubuntu VM on boot

I have a Ubuntu VM running in VirtualBox. I have a Shared Folder set up as myshare I have a folder created in my home directory (~/jamesw) as host. using the line sudo mount -t vboxsf myshare host ...
8
votes
1answer
2k views

Why should I use gksudo for Gtk apps instead of sudo? [duplicate]

I read somewhere that people should use gksudo for applications that use the Gtk GUI instead of sudo? What's the reasoning for this?
23
votes
6answers
32k views

sudo error, is mode 0777, should be 0440

I am getting sudo errors, how do I fix this error? sudo: /etc/sudoers is mode 0777, should be 0440 sudo: no valid sudoers sources found, quitting
9
votes
4answers
2k views

Why does echoing these parameters with sudo not work? [duplicate]

Possible Duplicate: sudo & redirect output These are suggestions given by powertop to save energy: echo 1500 > /proc/sys/vm/dirty_writeback_centisecs echo 1 > ...
5
votes
4answers
9k views

How to give shutdown privileges to a user?

I am using Ubuntu 11.04. I want to run a script which checks for a running process and shuts down the system when that process ends. To do this, the user requires shutdown access so that the script ...
4
votes
2answers
924 views

Unable to launch nautilus with sudo [closed]

When I run Nautilus with sudo, gksudo or Alt+F2, I get this error message: Initializing nautilus-gdu extension ** (nautilus:2352): WARNING **: Failed to get the current CK session: ...
0
votes
1answer
515 views

Is there a way to never have to put in your password after you have logged in? [duplicate]

Possible Duplicate: How to make Ubuntu remember forever the password after the first time I put my password in when I log in but after that I don't want to type it again. When I use my ...
4
votes
1answer
6k views

problems with sudo permissions - /var/lib/sudo owned by uid

my system is a new 11.04 ubuntu and i recently started working with LAMP. some how, when i tried to change permissions of the var/www/ for netbeans to work on the local server, and did something that ...
10
votes
6answers
3k views

Why can't non-admin users install software?

This is probably something I don't understand since I am used to Windows and am only starting out with Ubuntu. I know that software in linux comes in packages what I don't understand is why can't ...
6
votes
2answers
4k views

Password not working in Graphical Applications (gksu)? Works with sudo

I am having a problem where when I try to run say GParted, when I am prompted for a password, it says "Incorrect Password" But when I enter the same password using terminal sudo gparted for example, ...
14
votes
3answers
6k views

Broken sudo: can't open /etc/sudoers: No such file or directory

I have a live USB persistent version of Ubuntu 11.04 installed with Unetbootin. After some time I experienced some bugs while upgrading the kernel and trying to use my second screen on my laptop. ...
7
votes
1answer
626 views

Is it safe to run a GUI program as another user?

I need to run a program (libreoffice) as another user. I noticed that the program started in the background when invoked as kdesudo -u otheruser libreoffice, possibly to avoid social engineering ...
68
votes
8answers
26k views

How to avoid using sudo when working in /var/www?

I want to stop having to use sudo everytime I work in /var/www. How can I do that? I simply want to put all of my sites into this directory and work with them without too much pain.
1
vote
1answer
2k views

Unable to kill process with 'kill -9' whose PPID=1 and using 100% of CPU?

Direct Question: Flash under firefox 4.0, npviewer.bin, in KUbuntu 10.04 was running at 100% and I couldn't kill it. I tried: sudo kill -9 12996 sudo kill -15 12996 I logged in as root and ran ...
11
votes
3answers
23k views

Disable sudo permission to user from command line

I have activated root user in ubuntu and want to use ubuntu as server with no DE. For this I want to disable sudo privilege given to first user. How can I do this from command line ? I know I can use ...
2
votes
1answer
4k views

Simple file doesn't run (command not found!)

Here in the screen shot, there is a window and terminal open. I am running on Ubuntu 10.04(kernel 2.6) LTS 64bit LiveCD session, and trying to run testDisk to recover my another formatted ...
13
votes
4answers
5k views

What if I accidently run command “chmod - R” on system directories (/, /etc, …)

I accidently ran sudo chmod 755 -R / instead of sudo chmod 755 -R ./ I stopped it after few seconds, but now there is some problems such as sudo: must be setuid root How can I revert ...
43
votes
3answers
16k views

What is the difference between the 'sudo' and 'admin' group?

I noticed that two groups are granted similar-looking permissions in /etc/sudoers: # Members of the admin group may gain root privileges %admin ALL=(ALL) ALL # Allow members of group sudo to execute ...
27
votes
2answers
19k views

after upgrade gdb won't attach to process

I just recently upgraded from 10.04 to 11.04 and gdb won't allow me to attach to processes anymore I get the error Attaching to process 10144 Could not attach to process. If your uid matches ...
5
votes
2answers
1k views

How do I drop all elevated privileges through the terminal?

I did some authentication mounting where I added code like timestamp_timeout on sudoer. This setting will effect every mounting, where you must enter the user password. After entering the password ...
18
votes
6answers
33k views

How to run an application using sudo without a password?

... but still be required for applications that need admin privilegies? In order to allow the following: $ apache2ctl restart httpd not running, trying to start (13)Permission denied: make_sock: ...
1
vote
1answer
952 views

How to run a command with no-tty access, to run in admin privileges?

I would like to execute a command with administrative privileges, but do not have an access to the tty. I tried to execute it with the -A option of the sudo command and setting the environment ...
2
votes
0answers
191 views

What's the difference between sudo and gksudo when launching graphical applications? [duplicate]

Possible Duplicate: What is the difference between “gksudo nautilus” and “sudo nautilus”? It is common to see in instructions, the terminal command to edit a file: ...
1
vote
2answers
1k views

Wubi Install as Root User

Is it possible to install ubuntu from wubi with the root account (and have it show up in login screen, unlike when it is made manually with "sudo passwd root")?
3
votes
1answer
2k views

Ubuntu Server Automatically Insert Password Using Python3

I'm trying to create a small python3 program for my friend which will install and configure the nessarcary set-up for his Ubuntu Server. I want him to be able to start the program, give some basic ...
1
vote
1answer
954 views

Executing a Super-user command through .bashrc

Is it possible to execute a super-user command in .bashrc? And if so, how? It would save me having to execute "sudo /opt/lampp/lampp start" on each startup. I've considered using the LAMP stack from ...
15
votes
5answers
9k views

su command + authentication failure

I am having problems with the su command. I know my password and I am typing it correctly but su indicates authentication failure. So I checked on the internet and then went into recovery mode and ...
2
votes
2answers
181 views

Looking for a log thats bound to sudo

I've issued the commands sudo su, and sudo sh. Can you please tell me if there are logs associated with sudo, and where I could find them?
5
votes
3answers
14k views

Mounting filesystem with special user id set

I want to mount the device /dev/sda3 to the directory /foo/bar/baz. After mounting the directory should have the uid of user johndoe. So I did: sudo -u johndoe mkdir /foo/bar/baz stat -c %U ...
8
votes
1answer
565 views

how come sudo give root privileges for a user not in /etc/sudoers?

I just wonder how sudo privileges are found with ubuntu, from a technical point of view. Users with sudo privileges are not present in /etc/sudoers, so this looks a little bit exotic. Was the source ...
1
vote
1answer
190 views

How to detect another sudo process?

Whenever a command is "unable to lock the administration directory", is there any way to easily detect what process is running that is using sudo?