LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu
User Name
Password
Ubuntu This forum is for the discussion of Ubuntu Linux.

Notices


Closed Thread
  Search this Thread
Old 04-22-2006, 08:04 PM   #1
magnum81
LQ Newbie
 
Registered: Apr 2006
Posts: 13

Rep: Reputation: 0
su works but sudo doesn't work.


When I run "su" and enter the password I get access to a root terminal, but I can't "sudo" a command using the same password that I used to "su". So I su'ed to root and "passwd root" and entered a new username and password, then exited the su'ed session, but "sudo" still doesn't work. I have ubuntu.
 
Old 04-22-2006, 10:30 PM   #2
Freemor
Member
 
Registered: Aug 2005
Location: New Brunswick
Distribution: Trisquel
Posts: 70
Blog Entries: 8

Rep: Reputation: 15
I think this might just be some minor confusion on the password to use.

for su you use the password of the user you are switching to.

for sudo you use the password of the current user.

You also have to make sure that you user you are trying to sudo from has the ability to run things as root (i.e. is in the sudoers file and/or has 'executing system administration tasks' checked in their privileges)

From the sounds of it your problem is the former.. use your current password to sudo. This lets you give people the ability to run certain "administrator" tasks without needing to have them know the root password. the tasks they can preform can be limited by editing the sudoers file. 'man sudoers' at the command line will give you a rundown on that.

Hope this helps
Freemor

Last edited by Freemor; 04-22-2006 at 10:33 PM.
 
Old 04-22-2006, 10:52 PM   #3
Tinkster
Moderator
 
Registered: Apr 2002
Location: earth
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928
Please do not post the same thread in more than one forum. Picking the most relevant forum and posting it once there makes it easier for other members to help you and keeps the discussion all in one place.

http://www.linuxquestions.org/rules.php

http://www.linuxquestions.org/questi...d.php?t=437852

This thread has been reported for closure
 
  


Closed Thread



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
su to root works sudo doesn't magnum81 Linux - Security 4 04-22-2006 08:29 PM
sudo does not work powah Linux - Security 1 12-06-2005 04:49 PM
Permissions in Debian - sudo works, su doesn't (etch/64Studio) greennick Linux - Software 0 09-12-2005 03:04 PM
sudo doesn't work oomfoofoo Debian 3 08-13-2005 07:34 AM
sudo doesn't work mla Linux - Software 1 10-01-2003 08:24 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu

All times are GMT -5. The time now is 09:35 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration