Questions tagged [sudo]

sudo is a tool which allows users to run commands as another user (usually the root user)

sudo allows users to run commands as another user. It is typically used to allow trusted users to run commands as root, without giving them root access, or to allow a user to run commands as another user. Both of these uses must be allowed by the root user.

886 questions
-1
votes
2 answers

nested Cmnd_Alias in sudo configuration

im trying to simplify my sudo configuration but not sure if sudo supports this configuration. I have a "view" command alias which we use to provide access to log files: Cmnd_Alias VIEW = /bin/cat, \ /bin/zcat, \ …
Mark V
  • 121
  • 6
-1
votes
2 answers

su command works without prompting password

I'm on a RHEL server where the su command drops the user into root without prompting for a password. Obviously, this is a pretty big cause for concern which I'd like to fix. I'm not in contact with the previous admin, and he didn't leave any notes…
devnill
  • 307
  • 1
  • 2
  • 19
-1
votes
1 answer

running script containing sudo in cron

#!/bin/bash value=$(
user1597811
  • 101
  • 2
-1
votes
1 answer

Installing a python web framework on shared web host without sudo

I have a Cloud Linux shared web hosting service with a popular company. They provided python but not enough libraries for me to run a FLASK micro web framework. I do not have admin access,YUM, or PIP so I can run any install scripts. What would I…
Gabriel Fair
  • 71
  • 1
  • 10
-1
votes
3 answers

Unable to Sudo into EC2 server

When i type "sudo -i" on an EC2 instance, i get following error: sudo: must be setuid root Which means that someone has tampered with the sudo permissions. Now the only way to login to server and do administration was through "sudo -i". Is there…
Farhan
  • 4,269
  • 11
  • 49
  • 80
-1
votes
2 answers

sudo to the same ordinary user, without authentication

My script, when executed as root, uses the sudo without passwd, and that is fine. Sometimes however, I must execute that script as an ordinary user, which "switches" to itself by that sudo command. I must omit the passwd procedure in this case…
stoqlt
  • 81
  • 1
  • 5
-1
votes
4 answers

Linux /home privacy

Warrning: this is probably against Unix philosophy and desgin, but I will ask it anyway. Is there a way to achive privacy for three seperate /home/user folders? Problem which is rasing that question is that me and to other two guys have a VPS and…
notphunny
  • 3
  • 3
-1
votes
1 answer

Want to install GDB on Fedora 7 machine

I want to install GDB GNU debugger for debugging C Programs, onto my fedora machine.. I installed the gzip file from gnu website, but it gives error during MAKE command.. I am doing all the steps correctly which reading from the readme file, and…
RBA
  • 283
  • 3
  • 6
  • 16
-1
votes
1 answer

Allow user to execute sudo commands without inserting password

I have a Debian-based system (most likely an Ubuntu 18.04 LTS) with a user, say user, that executes an application (as a daemon). The system is not exposed to the Internet with a public IP address. This application needs to reboot, stop processes…
EM90
  • 99
  • 3
-2
votes
1 answer

Permission denied when executing perl via sudo

Command: ssh user@testhost "sudo -u tester env PERL5LIB=/home/tester/perl5/lib/perl5 /home/tester/perl5/bin/testperl" Result: Can't locate testperl.pm: Permission denied at /home/mogile/perl5/bin/testperl line 15. How can I fix the problem?
petertc
  • 2,500
  • 1
  • 15
  • 10
-2
votes
1 answer

Is it possible to "sudo su" using ssh in bash?

#!/bin/bash USERNAME=ksmith HOSTS="linux1" YUPDATE="sudo yum -y update" FIXDATE="sudo -u echo -e 'ZONE="America/New_York"\nUTC=true' > /etc/sysconfig/clock" for HOSTNAME in ${HOSTS} ; do ssh -tt -l ${USERNAME} ${HOSTNAME} "${YUPDATE};…
-2
votes
1 answer

can't switch to root or use sudo

I've just come into the following problem: For some reason I can't use su or sudo: usr@usr-MS-7816:~$ su Password: su: Authentication failure usr@usr-MS-7816:~$ sudo su [sudo] password for usr: usr is not in the sudoers file. This incident will…
user2394156
  • 107
  • 1
  • 1
  • 3
-2
votes
1 answer

sudo yum install httpd is throwing errors

Hello this is the command im typing and its returning the error you see, any suggestions please [ec2-user@ip-172-31-41-46 ~]$ sudo yum install httpd Loaded plugins: priorities, update-motd, upgrade-helper Resolving Dependencies --> Running…
cppit
  • 149
  • 1
  • 1
  • 9
-2
votes
3 answers

Enable Passwordless Sudo with Arguments

I am trying to enable passwordless sudo for updating yum on a RHEL box. I have the following line in sudo visudo. myuser ALL=(ALL) NOPASSWD: /usr/bin/yum update After doing this under myuser I am still unable to update yum without giving my sudo…
Jacob Waller
  • 135
  • 5
-2
votes
1 answer

sudo permissions without root access

I want to give certain users on my server access to run commands as apache, but I don't want to give them full root access. Is there a way to allow a user to run a command similar to sudo -u apache ... while preventing them from having root…
ajon
  • 309
  • 4
  • 11