LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 03-16-2005, 07:01 AM   #1
TroelsSmit
Member
 
Registered: Feb 2004
Location: Denmark
Distribution: Debian / Suse
Posts: 223

Rep: Reputation: 30
ubuntu, I can no longer become root or have root rights


Hi,

I installed ubuntu without ever being asked for a root password (afaik).

I created a user named t with password xxx.

I logged onto the system.

I was able to start a "root terminal" specifying t's password xxx.
I could never start a terminal and do a "su".

I used visudo to add t to the sudo users.

I changed the userid t to ts and the password from xxx to yyy.

- Now I can't start a root terminal - it says "child process failed -1".
- I can't sudo because the user t changed to ts and is no longer in the sudoers file.
- I can't "su root" from a terminal window - password fail with both password xxx and yyy.

I need root rights - and I am the only user of the machine, can anyone see a solution ?

The system is Ubuntu with Gnome.
 
Old 03-16-2005, 07:04 AM   #2
XavierP
Moderator
 
Registered: Nov 2002
Location: Kent, England
Distribution: Debian Testing
Posts: 19,192
Blog Entries: 4

Rep: Reputation: 475Reputation: 475Reputation: 475Reputation: 475Reputation: 475
There is no root account under Ubuntu, so using "su" to become root will fail. By design, you are supposed to issue any commands that need root access by sudo (your user account is already a sudo'er.

Therefore:
Code:
sudo <program>
[enter your password]
will work.
 
Old 03-16-2005, 08:08 AM   #3
TroelsSmit
Member
 
Registered: Feb 2004
Location: Denmark
Distribution: Debian / Suse
Posts: 223

Original Poster
Rep: Reputation: 30
If you read my post you will see that the "sudo" command did no longer work because I changed my username.

I solved the problem using the "live" cd with the root terminal, called visudo on the /mnt/hda1/etc/sudoers file with a -f parameter.
 
Old 03-16-2005, 08:08 AM   #4
TroelsSmit
Member
 
Registered: Feb 2004
Location: Denmark
Distribution: Debian / Suse
Posts: 223

Original Poster
Rep: Reputation: 30
thanks anyway
 
Old 03-24-2007, 04:52 AM   #5
mustafa parlaktuna
LQ Newbie
 
Registered: Aug 2006
Location: eskişehir turkey
Distribution: ubuntu 6.06
Posts: 9

Rep: Reputation: 0
ı think you can become root by writing sudo su. It asks you your account password.
 
Old 03-24-2007, 08:17 AM   #6
pixellany
LQ Veteran
 
Registered: Nov 2005
Location: Annapolis, MD
Distribution: Mint
Posts: 17,809

Rep: Reputation: 743Reputation: 743Reputation: 743Reputation: 743Reputation: 743Reputation: 743Reputation: 743
To enable the root account in Ubuntu:

sudo passwd root
enter your user password
enter the new root password at the prompt

The one and only flaw in Ubuntu--fixed in 15 seconds.......
 
Old 03-24-2007, 08:19 AM   #7
pixellany
LQ Veteran
 
Registered: Nov 2005
Location: Annapolis, MD
Distribution: Mint
Posts: 17,809

Rep: Reputation: 743Reputation: 743Reputation: 743Reputation: 743Reputation: 743Reputation: 743Reputation: 743
PS
I was not aware that you could CHANGE a user name....You can certainly create new users and delete users---and you can change the privileges of exisiting users
 
Old 03-24-2007, 07:17 PM   #8
sumguy231
Member
 
Registered: Apr 2004
Location: North America
Distribution: Kubuntu 7.04 - Feisty Fawn
Posts: 296

Rep: Reputation: 30
I don't know how you got yourself into that, but I suppose you could just boot into single-user mode (Press Esc before booting to enter the Grub menu and choose 'Recovery Mode') and add yourself to /etc/sudoers. Barring that, you could use any Linux LiveCD to edit it and fix the problem.
 
  


Reply



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
Root/User rights to Root commands? mrde50garfield Linux - Software 2 10-24-2006 05:42 AM
Linux root rights dstjames Linux - Security 3 07-24-2004 05:27 AM
Non root rights in Mozilla dazzlehank Slackware 5 01-19-2004 03:47 PM
root has lost its rights DoubleM Linux - General 3 03-19-2003 02:10 PM
root rights tfrye Linux - Security 1 12-20-2000 02:28 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 03:31 PM.

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