Slackware :: Sudo Does Not Allow Access To Root Commands

Feb 22, 2011

In order to allow me to shutdown my PC from within fluxbox without being root I ran "visudo" and added the following line:

Code:

psionl0 ALL=(ALL) NOPASSWD: ALL

A check that the line had been accepted showed all ok:

Code:

bash-4.1$ sudo -l

User psionl0 may run the following commands on this host:

(ALL) NOPASSWD: ALL

Yet when I tested it out, I got nowhere:

Code:

bash-4.1$ sudo pkgtool
sudo: pkgtool: command not found
bash-4.1$ sudo shutdown -h now
sudo: shutdown: command not found
bash-4.1$

Have I done something wrong or isn't sudo meant to be used this way?

View 12 Replies


ADVERTISEMENT

General :: Can't Execute Commands As Sudo Nor Access Sudoers File In Mandriva 2010.1

Aug 16, 2010

since a recent upgrade to Mandriva 2010.1 I am not able to 'sudo' as administrator or when I use the 'root' password. I am the only user on this machine (Dell Inspiron 530S multi-booted with Window's Vista Home Premium, Ubuntu 10.4, and Mandriva 2010.1). I can get into the 'Manage Users' section of the control center by authenticating as 'root' but I can't access 'sudoers file' from command line.

View 4 Replies View Related

General :: Commands To Use When Access The Parallelport Through Root

Oct 14, 2010

I have this project and it needs me to write a programe that will interface with a hardware device thruogh the parallelport.I did that, but I feel i might be using the wrong commands because when runing it i get a segmentation fault or a 'changing ownership of file ; operation not permitted.

View 2 Replies View Related

Ubuntu :: Get Root User Access Without Using Sudo?

Apr 23, 2010

It's been a few years since I last installed Ubuntu. I searched the forums and can't seem to find the answer. I want to be able to do a "su root" and have root access. I know Ubuntu wants you to do the sudo command, and I know you can really mess things up being root. I know I got this to work before. What do I need to do?

View 3 Replies View Related

General :: User Access To Commands Having Root Privileges?

Oct 14, 2009

How to allow access to some commands having root privleges to be run by non root user. I am new to unix/linux and I have a major assignment. I have to find ways to run particular commands which can be run only by root from a non root user. I know sudo is one of the way but i need some different approach.

View 8 Replies View Related

Slackware :: Running Root Commands As User?

Nov 7, 2009

After a few hours work I have managed to set up pptd so that my daughter can log into her account at Imperial College. My problem now is that I need to have a script that she can run if she wants to log in. She will have to invoke a couple of root commands and I do not want to give her the root password What she needs to do to set up networking is:

Quote:

pppd call imperial dump debug logfd 2 nodetach require-mppe
/sbin/ip route add default dev ppp0

How can I enable things so that she can run this script as user?

View 12 Replies View Related

Slackware :: Start Thunar As Root - Won't Run After Sudo

Jun 1, 2011

I have been using ubuntu or a derivative distro and perhaps I grew too used to sudo. If it matters I am on Slackware 13.37 and xfce4. I was able to adjust sudoers to allow sudo but I am having difficulties running some progs as root. The biggest concern is trying to start thunar as root. It wont run after sudo, su, or su -l. What am I doing wrong?

View 10 Replies View Related

Server :: Server Runs Commands Slowly / Root "sudo Mc" And Takes To Boot?

Sep 1, 2010

I have debian lenny, when I run an application is slow to load (example: iceweacel open and it takes, I can hold him iceweacel work normally), I tried to change from gnome to another and the same thing, went down some services (samba, squid) and nothing. I open a terminal and it takes, I want to duplicate it and do it fast. From a terminal without X (tty1) with root run mc and moves quickly, also run as root "sudo mc" and takes to boot.Any action done with sudo it takes to run.

Can not be what it takes to make starting the applications, not the PC because it is new, and from one moment to another I began to pass this

The sudoers file is fine, in the log's nothing unusual, since other PC take long to enter samba.

View 1 Replies View Related

Ubuntu :: The "sudo Cp -r" Command Set The Destination Folder To Only Root Access?

Feb 27, 2010

Before, the "sudo cp -r" command automatically set the permissions to make the directory / files can be accessed by others.

But, after I reinstall Ubuntu 9.10 and apply all the latest updates, "sudo cp -r" command set the files to be accessible by root only.

After I copy the codecs directory to /usr/lib by using the above command, not only I cannot view the files inside, SMPlayer and other player software cannot access the directory.

To fix this, I have to run the chmod command to change the permissions.

Does anyone face this problem? Was it caused by the installation of latest updates?

View 6 Replies View Related

General :: Sudo Cd /root Gives Sudo - Cd - Command Not Found

Jan 6, 2011

Kernel 2.6.21.5, Slackware 12.0

Code:

Code:

On the other hand

Code:

So, I do not understand why the notification "sudo: cd: command not found", considering cd is a bash built-in command.

View 3 Replies View Related

Ubuntu :: Can't Cd To Root Acount /home In Terminal - Sudo Cd /root Fails?

Jul 25, 2011

can't cd to root acount /home in terminal - sudo cd /root fails?

View 3 Replies View Related

OpenSUSE Install :: Revert The Changes Or Change The Permissions Again To Root:root Or Make Sudo Work

Aug 10, 2011

Accidentally I changed the ownership of all the directories under / to my own instead of root:root. Now I am unable to use sudo and many bad things are happening. Is there a way to revert the changes or change the permissions again to root:root or make sudo work ?

View 3 Replies View Related

General :: CentOS / Sudo Doesn't Accept Root Password But Logging In As Root Works

Apr 9, 2010

I was trying to edit a file requiring root permissions, so I used sudo. I typed the root password and it failed. This happened three times, and the process was ended. I then logged in as root (su) and was able to navigate to the file and make changes as root. Am I missing something? How would I edit the sudoers file such that this password would work? Or is there another way to log in to the sudo group to make these changes? How do I set sudo passwords?

View 1 Replies View Related

Ubuntu :: Can't Do Any Sudo Commands In Terminal

Mar 20, 2010

I was following a guide to stop Ubuntu from always asking the root password. And apparently i messed something up in vsudo edit or something like that i was in... So now when i put in a sudo command i get this...

Quote:

>>> /etc/sudoers: syntax error near line 18 <<<
sudo: parse error in /etc/sudoers near line 18
sudo: no valid sudoers sources found, quitting

so i cant even get back to undo what i edited.

View 8 Replies View Related

Ubuntu :: Unable To Use Sudo And Su - Commands

May 23, 2011

I am unable to use sudo and su - commands. check my output below:

Code:

ubuntu@user1:~$ su -
Segmentation fault
ubuntu@user1:~$ sudo visudo
bash: /usr/bin/sudo: Permission denied

[code].....

View 9 Replies View Related

General :: Sudo - Run All Commands With Password?

Feb 16, 2010

Having a problem with sudo. I'm down as a user who can run all commands as root provided I enter my password. The relevant line from my /etc/sudoers file :

Code:

user1 ALL=(ALL) ALL

There are several commands that I run quite frequently such as mount and fdisk but would like to avoid having to enter a password each time I use them. What would be the appropriate change to the sudoers file ?

UPDATE: I neglected to scroll down to the bottom of the /etc/sudoers file where there was the line :

Code:

%admin ALL=(ALL) ALL

and since user1 was a member of the admin group any predeeding lines were being overidden by this. Commenting out this line and adding

Code:

user1 ALL= NOPASSWD: /bin/mount, /sbin/fdisk

View 1 Replies View Related

Security :: Sudo To Disallow Certain Commands?

Jan 10, 2011

trying to devise a new sudoers configuration while building a new SOE and would like to force everyone (including system administrators) to use rootsh in favour of doing things like sudo -s, sudo bash, sudo tcsh and so forth. Effectively, use sudo to use any shell other than rootsh. Is there a way to allow users to run anything they want except shells. I realise this is a default permit which inherently is defective, but I'm not convinced that going through the 1559 executable commands of my (as yet incomplete) built system to decided on the likely 1000+ commands I would want to be genuinely allowed. As I said this is for system administrators first, and I'd like to forcibly instil the habit of sudo <command> or using rootsh to get an audited shell. But I know people are already not doing enough sudo <command> as it stands, rather they switch to bash.

View 7 Replies View Related

Ubuntu :: Edit Which Commands Require Sudo?

Aug 2, 2010

is there a way to edit which commands require a sudo? or some programs, like the CPU frequency monitor on panel, requires a password to change. where would i start if i want to change this?

View 2 Replies View Related

Ubuntu Servers :: Set Sudo Commands Restrictions

Nov 7, 2010

does anyone know how to set restrictions on the commands a user can run as sudo? i want to make it so they can only halt the system.

View 1 Replies View Related

Ubuntu :: Where To Enter Commands Like $ Sudo /usr/etc/eth0

Aug 28, 2010

I am a Mac/ Windows user, forced to use Linux for my college work. I do not know where to enter commands like $ sudo /usr/etc/eth0 mvntz -do4i or how to make them work

I had a problem - the Wi-fi card in my laptop was not working. All the forums were useless. They wanted me to READ about wireless networking !

Finally a good friend solved the problem in a simple way : it appears Ubuntu has not installed the drivers for my Broadcom wireless card since it was not open source. I had to download it myself. Here is how : Go to System menu on the top bar. Choose administration/ hardware devices. Tell it to activate the device. It will download the drivers through the cable attached to DSL modem and install.

Then clicked the network icon, selected edit connections, and entered my wireless network name and password. This solved all problems.

Why doesn't Linux give me a warning that the driver for something is not yet installed ? When I was struggling with the network setup wizard for the whole day, there was no clue about the missing driver.

View 6 Replies View Related

General :: How To Allow User To Execute All Commands Without Sudo

Apr 30, 2010

Customer asked me to create a menu for linux he also asked me to do this: Open like a command like where a user can execute commands...so for this the users have sudo enabled. The code below works OK. But it has an issue when a command is executed but the command does not need sudo

Like for instance
Code:
cd /
sudo: cd: command not found

How can I allow a user to execute all commands when a command does not need sudo
Code:
echo -e "Press Control+C to finish"
#echo -e " "
while true;
do
read whichcmd?"Insert Command: "
sudo $whichcmd
done

View 3 Replies View Related

General :: Setting Up User To Use Sudo For Specific Commands?

Jan 17, 2011

I did some digging on the sudo command and I do know the config file is /etc/sudoers Read the manual for sudoers and found out that I must use visudo to edit the file I read some of the examples at the bottom of the file and tried entering my own account in following the example. one of the commands I was trying to allow my account to perform without root login is the mount command So I tried adding this in (kreid8 /bin/mount ALL) I then saved & exited the file and logged out of root and tried sudo mount -t vfat /dev/sdc1 /media. I got an error saying I had to be root in order to do that But when I use the visudo -l option it shows that I have that privellege. Did I edit the file incorrectly?

View 6 Replies View Related

Programming :: Automate The Password Prompt Required For Sudo Commands?

May 31, 2011

I have written a script to run commands on remote servers, it is working fine. But when I am running "sudo commands" on the remote servers, it asks for me password after prompting for ssh password. I am unable to automate this password prompt (which is just after ssh password prompt). This is the function I am using to provide passwords

Code:

pass ()
{
cd $DIR/"$dt1"_"$dt"
/usr/bin/perl << 'EOF'
use strict;

[code]....

I want the same function to be used , when it expects for sudo passwords for any of the below lines:

Code:

[sudo] password for vikas: orPassword: This is my "cmd" file passed in pass () function.

Code:

ssh -t -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no 192.168.1.100 "bash rcmds"

This is my script output

Quote:

[vikas@box1 ~]$ ./rscript.sh
++ rm -rf /home/vikas/May_31
++ mkdir -p /home/vikas/May_31
++ set +x

[code]....

how to automate the password prompt required for sudo commands.

View 8 Replies View Related

Ubuntu :: Commands - Sudo Kill -9 -1 - Screen Became Blank - Keyboard Not Responding

Jul 11, 2011

I am learning linux commands. I just wanted to see what happens when I type

Code:

The screen became blank. Keyboard was not responding. I couldn't do a proper shutdown. I switched off computer by pulling out the plug. When I restarted, I heard a series of beeps (approximately 10 beeps). Then I was dropped to the grub prompt. The problem now is I can not type anything into the grub prompt, because the character 'c' is continously printed across the screen like this:

Code:

I couldn't stop the character 'c' from printing (I tried pressing Esc, Ctrl+C)

The solution is easy. I can reinstall grub from a livecd. Or even reinstalling the entire operating system wouldn't take more than 30 minutes. But I want to know:

1) What exactly happened to grub? What stage does this error belong to (1, 1.5 or 2)? What is the error number?

2) How can running "sudo kill -9 -1" affect grub?

View 5 Replies View Related

Security :: Run Commands As Root ?

Mar 4, 2010

I need to launch a bash file in Linux from an unprivileged user session, file that will run bash commands as root. But I do not want to create an user with root privileges to do that also the process must be silent (no password asked).

How can I do this without adding a user in sudoers and without giving rights to all users to execute the commands from that bash file?

I have tried SUID option witch would had been good as functionality but I understand that SUID doesn't work for script bash files.

View 14 Replies View Related

Security :: Log All The Commands Executed By Root ?

Aug 11, 2010

I want to get a of log all the commands executed by the root user with the following details :

incoming ip
username (thru which su was executed)
time and date
all the commands executed as mentioned above.

Also if user has managed to login as root, he should not be able to disable / delete the above info. Can this info be collected at some other physical server ?

View 5 Replies View Related

Programming :: Root Commands In SSH Script

Mar 1, 2011

I am trying to administer a small group of ubuntu desktops in my classroom. I can use ssh to perform administrative tasks one at a time on each machine, but I want to automate these tasks through a small number of scripts. I am having trouble with running root commands through a script.

On other distros, I think I would simply ssh into the root account, and run the script. But as an ubuntu user, I have only ever used sudo, and folks at ubuntuforums are understandably hesitant to recommend logging in as root. Instead I am seeing suggestions to disable the password requirement for each specific command I want to run, which does not seem like best practice.

Should I enable the root account, give it a password, and ssh to the root account to run the scripts? To be specific, the scripts will do things like install updates, install programs, add or delete users, configure the desktop, etc.

View 5 Replies View Related

General :: Server Terminal Keyboard Shortcut "F5" To Run Commands Sudo Apt-get Update

Sep 10, 2010

I was wondering is there a way to bind say "F5" to the command sudo apt-get update so I can press one key to write this into the terminal?

View 1 Replies View Related

Fedora :: Sudo And Root Desactivated Rather Than Su?

Oct 1, 2010

I use Fedora 13 LXDE and I want to know how to use sudo with my user passwordnd desactivate the root account rather than the su command like Ubuntu distribs

View 7 Replies View Related

Ubuntu :: Become A Root User Without Using Sudo?

Nov 6, 2010

How to become a root user without using sudo?So,that i can become super user to edit configuration files in etc directory.

View 1 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved