Tagged Questions

Sudo Command The sudo command is a program for some Unix and Unix-like operating systems that allow a user to execute programs with the security privileges of another user. Typically those of a superuser or the root user. Through a configuration file, usually known as a sudoers file, an ...

learn more… | top users | synonyms

1
vote
3answers
57 views

Use sudo command for script SSH server

I have to do following steps on several servers: log in with my username type in sudo su - type in amCLI -l 32/1 | grep Firmware So I would like to write this all in one script, my idea was: ...
1
vote
1answer
27 views

sudo command trying to search for hostname

Recently, I have changed the sudoers file and the hostname through /etc/hostname. After changing this files, my sudo command is taking a lot of time. Also, it says sudo unable to resolve host ...
1
vote
1answer
21 views

sudo not working alongwith su

I am using a Ubuntu system. Today, I accidentally changed the sudoers file in /etc due to which my normal user prathmesh is not able to perform sudo operation. I don't know how to go to the root mode. ...
0
votes
2answers
51 views

How do you create a user with read and write access to another user's home directory

I am new to Linux and need some help how I can create a user with some special rights. I have read a few articles and "how Linux permissions work" but have not yet understood how it works in ...
4
votes
3answers
228 views

Running chrome in Backtrack Linux

I am using the Backtrack 5 linux distribution, and i wanted to install chrome, but it wont run as root for default. I know that using --user-data-dir will let me run it as root. But is there a safer ...
1
vote
1answer
59 views

sudo access to view/edit a crontab

I wish to be able to edit, or at least view, a crontab that is on a server. Should I not be able to run this to do so: sudo crontab -u root When I do, I get this error: Sorry, user crmpicco is ...
0
votes
2answers
603 views

“sudo nautilus” does not allow changing files or folders

I can't modify files in Ubuntu 12.04. I'm trying to change the permissions so that I can add a folder or change a file and all I get is this: $ sudo nautilus sudo: /usr/lib/sudo/sudoers.so must only ...
1
vote
1answer
44 views

Why is “sudo unmount” required for unmounting an sshfs-mount if it was mounted without sudo privilges?

I have an sshfs FUSE filesystem mounted in ~/mountpoint. I tried umount mountpoint and diskutil unmount mountpoint (on a Mac here) and both failed. I used sshfs -o IdentityFile=<key> ...
0
votes
1answer
31 views

group configuration in visudo

So I was trying to grant user name shutdown as root permission. I created a shutdown group and add my username using: groupadd shutdown usermod -A shutdown annguyen Afterward, I logged in a as root ...
2
votes
3answers
83 views

Different SSH/Login Password From SUDO Password

I'd like to use a different password to elevate my user to sudo status than the password I use to login (either via GUI, shell, or SSH) to my account. Is this possible? EDIT: Since setting the root ...
0
votes
2answers
39 views

What is “Sudo -Hiu” for?

I followed a tutorial to install Hudson server. And, in the tutorial had a linux command: sudo -Hiu hudson which hudson is a username in ubuntu. But I dont know what is "sudo -Hiu" for? What ...
4
votes
2answers
66 views

Feedback when typing password at a sudo prompt

When I type in my password at a sudo command line prompt, I would like to see a "*" for each keystroke. How do I do this?
0
votes
1answer
47 views

How to proxy sudo

Me and one other developer just inherited a web application from a team that has now been re-purposed to something else. Ironically, although we are responsible for maintaining and developing the app, ...
1
vote
1answer
23 views

How to securely allow a custom daemon to restart a proxy?

I have a custom daemon which manages a blacklist for my proxy (HAProxy). When the blacklist is updated I need to reload haproxy so that it has the most recent proxy. Unfortunately manually reloads of ...
0
votes
2answers
59 views

Protecting against sudo inside shell-scripts, makefiles, etc

Usually, when I run sudo, it will ask me to enter a password the first time and it will remember that I'm authenticated for the next few minutes, until that authentication times out. This leaves a ...
2
votes
1answer
94 views

Permission issue with emacs for non-root user (Ubuntu 11.10)

Background I'm working on my personal VPS configured mostly for learning sysadmin and personal projects. Have run up against an issue where my non-root user could only create/edit files in emacs by ...
0
votes
2answers
63 views

Have sudo create files under your own user id?

If I wanted to do something like sudo fdisk -l > test.txt but I wanted test.txt to be under my own user ID (and not root) without having to chown it afterwards, is there a way to do this? ...
1
vote
2answers
114 views

Removing MySQL completely on Linux

I'm fairly new to Linux, when I first installed MySQL it was during an LAMP setup on personal machine with a Ubuntu Setup. ATM, I'm trying to get a fresh, clean install of only MySQL. I've been to ...
2
votes
0answers
26 views

MacPort and LaunchAgent without sudo

I'm running Snow Leopard and am trying to install Wine. To keep things simple, I'm trying to install Wine using MacPorts. My MacPorts is local to ~/opt/local/. However, one of the required packages ...
-1
votes
1answer
56 views

Unable to use command line on Mac OS X

I can't use my command line (terminal). sudo gem install compass but I only get "command not found". I'm admin om my Mac and my password is not blank. I've also tried this: defaults write ...
0
votes
0answers
124 views

sudo su and ssh localhost are failing

When I try to do sudo su I get the following errors. sudo: /etc/sudoers is mode 0777, should be 0440 sudo: no valid sudoers sources found, quitting I tried following the post ...
0
votes
1answer
89 views

hardening a server: disallow password-login for sudoers and log unusual ips

Two question regarding sudo-login into an ubuntu-system (debian tips welcome as well): Is it possible to require sudoers on my box to only login with publickey-authentication? Is it possible to log ...
0
votes
4answers
75 views

How can I switch back normal mode from sudo mode in Linux and Mac OS X?

I use "sudo su" command to do something in Mac OS X but don't know how to switch back. Hope you guy can do me a favor. Thank you!
-1
votes
1answer
46 views

Command can not run with sudo [closed]

Possible Duplicate: Can't run command with sudo, even with the full path, I got an error $ which starling /home/keating/.rvm/gems/ruby-1.9.2-p290/bin/starling $ sudo which ...
0
votes
1answer
109 views

Can't run command with sudo, even with the full path, I got an error

The command starling is located at /home/keating/.rvm/gems/ruby-1.9.2-p290/bin/starling. Only using rvmsudo starling will work properly. This is the result of me trying to invoke it in various other ...
3
votes
1answer
85 views

What is the + at the end of Unix permissions in a long listing format?

Here's an example drwxr-xr-x+ 6 reza reza 204 Mar 5 20:23 .ssh/ Although I am the owner of this directory, I cannot modify it without using sudo! Why is that? how can I remove '+' here ...
0
votes
1answer
93 views

sudo in CentOS 6.1 does not preserve command aliases as sudo elsewhere does?

On a stock CentOS 6.1 installation, if I start in my user shell (tcsh) with all my usual command aliases and do what I normally do (in other versions of Linux, and Mac OS X) to get a root shell, ...
0
votes
1answer
75 views

Suspicious root ssh process

A friend of mine sends me this. He is afraid that process 7680 is an intruder. Is it possible ? Could it be that he had run a sudo command (that would have forked a shell?). He mentioned connecting on ...
1
vote
0answers
41 views

sudo: preserve non-std file descriptors

Long story short: why isn't this (simplified) sample working? root:# sudo -C 3 -u regular-user cat /dev/fd/3 3< /var/log/syslog cat: /dev/fd/3: No Such file or directory There is a file that ...
1
vote
1answer
169 views

How to run python script on startup with sudo permission on Mac OS

I have created a script with python that basically ping all servers found in my lists. I need this script to be run on startup with sudo permission. So the question is, How do you run the script on ...
1
vote
2answers
97 views

How to have sudo remember the password across various entries

sudo asks for the user's password every so often when using bash. The answers to this explains how to change that time out. I was wondering, however, whether it would be possible to sync this. I have ...
0
votes
0answers
81 views

mount remote share as root via sudo, sftp

I completely removed root from my system, so I cannot login as root. I only have sudo enabled. This works well for the most part; however, I need to do somethings remotely with root permissions. ...
0
votes
0answers
49 views

Installing setup using sudo in Python

I'm getting a strange output when trying to install setup.py for a project. Any clue as to what I'm doing wrong? $ sudo python setup.py ...
0
votes
1answer
95 views

Installing setup using sudo in Python

I'm getting a strange output when trying to install setup.py for a project. Any clue as to what I'm doing wrong? $ sudo python setup.py ...
0
votes
2answers
578 views

sudo make install: permission denied

I have a most annoying question about building from sources. I've searched for an answer for a long while and nowhere can I find one... I've compiled software from sources before and this just baffled ...
7
votes
5answers
533 views

Why does “sudo -u root echo `whoami`” not return root?

How do you use sudo to run a command as the actual root user on Ubuntu? I originally thought this was the default behavior of sudo, until I ran: myuser@localhost:~$ sudo echo `whoami` myuser ...
1
vote
3answers
230 views

Sudo segmentation fault in Terminal [closed]

Possible Duplicate: Cannot do sudo: “/etc/sudoers is mode 0740, should be 0440” sudo: /etc/sudoers is mode 0640, should be 0440 Segmentation fault Any time I am trying to do ...
2
votes
1answer
120 views

Recording user activity if they have “sudo bash” access

I would like to monitor all the commands when a user calls sudo bash, including the rest of the commands.
0
votes
1answer
115 views

sudo makes me “lose” permissions when running a script?

I have a script that I need to run. It is kicking off a java program. When I run it as me, it seems to work fine. If I type "sudo myscript.sh" it does not run fine. In reality, I need to run it as ...
0
votes
1answer
251 views

Sudo with scp - transfering local file to remote server using ssh

So I'm running the following command scp \desktop\myfolder\deployments\myfile.txt user@host:/path/to/whereyouwant/thefile In an attempt to transfer a file from my local windows 7 machine to a ...
0
votes
1answer
234 views

passwordless sudo apachectl

I'd like to be able to restart apache under OS X Lion without entering a password. I tried placing this in /etc/sudoers: <User> ALL= NOPASSWD: /usr/sbin/apachectl But when I execute apachectl ...
0
votes
2answers
616 views

How to restore sudo privilege with Linux live CD?

I'm running Linux Mint 11 and I lost the privilege to use sudo, apparently the result of accidentally removing myself from the admin group. When I use the groups command to list the groups I'm in, it ...
1
vote
1answer
220 views

How to get the env vars I want with the superuser command?

I'm running OpenSuse 12.1 KDE. I was previously running Ubuntu. In Ubuntu there was a superuser option (sudo -s) that preserved the original user's HOME env var (and another option, sudo -i, that set ...
1
vote
1answer
65 views

How do I create a command to run with sudo?

I have created a file called svrestart in /home/gab/bin (which is a folder that should be automatically be added to path on startup) which contains: /etc/init.d/nginx restart /etc/init.d/php5-fpm ...
1
vote
2answers
79 views

custom sudo command

How can I make custom functions accessible to the sudo command? I have my Mac OS X set up with Bootcamp, but also with VirtualBox so I can run Windows for testing websites in IE. I have to run this ...
0
votes
1answer
212 views

“You are not in the sudoers file” error after running sudo command

I tried using a sudo command on my iMac to create a bootable version of Ubuntu, but when I run the command by pressing enter, I got the warning that the command might screw up my system, which I ...
1
vote
3answers
1k views

bash: sudo: command not found on OS X Lion

This baffles me. sudo [any command here ] bash: sudo: command not found Eek! I tried to uninstall the Ruby Version Manager (it wouldn't compile Ruby for some reason). Somewhere in following their ...
1
vote
3answers
184 views

Why does vi and sudo vi give me different version of vim?

The default version of vi that comes with Ubuntu Hardy is the 7.1 or 7.2. So I installed vim 7.3 from sources. Then to make it convenient I added this to my .bashrc alias vi='vim' In order to let ...
0
votes
2answers
58 views

Ubuntu 11 Desktop without an administrator user

Somehow I managed to change my user to a "standard" account, as opposed to an administrator account, and I don't have any access to sudo, or a backdoor account with admin rights. Is there anyway I ...
0
votes
1answer
153 views

sudo does not preserve PYTHONPATH

I modified /etc/sudoers (using visudo) to keep environment variables : Defaults !env_reset # Host alias specification # User alias specification # Cmnd alias specification # User privilege ...

1 2 3 4 5