LinuxQuestions.org
Register a domain and help support LQ
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 02-09-2012, 07:04 AM   #1
Adol
Member
 
Registered: Feb 2011
Location: Osaka, Japan
Distribution: Gentoo, Opensuse
Posts: 262

Rep: Reputation: 5
I just lost root acess


Hello,

Not really sure what happened. Everything was working well. I took a lot of time to build a gentoo machine exactly the way I wanted it and have been using it for almost a month now.

I just rebooted and now its saying my su password is not good. Permission denied.

It seems that I just lost root access to my machine. Is there anything I can do? I really dont want to build everything again because it takes a long time.
 
Old 02-09-2012, 07:33 AM   #2
acid_kewpie
Moderator
 
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1974Reputation: 1974Reputation: 1974Reputation: 1974Reputation: 1974Reputation: 1974Reputation: 1974Reputation: 1974Reputation: 1974Reputation: 1974Reputation: 1974
reboot, at your grub bootloader menu, hit e to edit, and add a "1" to the kernel options line. This will log you right in as root and then you can run "passwd" to set it again.
 
1 members found this post helpful.
Old 02-09-2012, 09:01 AM   #3
Adol
Member
 
Registered: Feb 2011
Location: Osaka, Japan
Distribution: Gentoo, Opensuse
Posts: 262

Original Poster
Rep: Reputation: 5
Thank you very much.

I was able to start as root and change my password but I still cant get root access when I log into my regular system.

I keep geting
Code:
petreuss@linux ~ $ su
Password: 
su: Permission denied
 
Old 02-09-2012, 09:17 AM   #4
Cedrik
Senior Member
 
Registered: Jul 2004
Distribution: Slackware
Posts: 2,140

Rep: Reputation: 242Reputation: 242Reputation: 242
Maybe it is other error than password error

I mean try a wrong password to see if error is the same
 
1 members found this post helpful.
Old 02-09-2012, 09:24 AM   #5
Adol
Member
 
Registered: Feb 2011
Location: Osaka, Japan
Distribution: Gentoo, Opensuse
Posts: 262

Original Poster
Rep: Reputation: 5
Thank you everyone. I got it working.

I tried to add my user to the cdrom group by using:
Code:
usermod -G cdrom (username)
I thought that it would append the cdrom group to my username but instead it put my user in only one group.

I fixed it by going to root from boot up with acid_kewpie`s suggestion and adding my user to all of the groups:
Code:
usermod -G users,wheel,audio,cdrom (username)
In my case the wheel group is important for getting root acess.

Thank you very much.
 
Old 02-09-2012, 09:32 AM   #6
Cedrik
Senior Member
 
Registered: Jul 2004
Distribution: Slackware
Posts: 2,140

Rep: Reputation: 242Reputation: 242Reputation: 242
Next time use -a (append) option for usermod
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
Does not acess root passward from user login sushant_pawar Linux - Security 2 11-26-2009 08:50 AM
Lost root password? skaldicpoet9 Slackware 8 03-02-2009 03:14 AM
Check to see which users have root level acess harsh5235 Linux - Newbie 2 05-21-2008 07:40 PM
root acess? SnowSurfAir Linux - Software 12 08-08-2003 05:27 PM
/root help I'm lost hiwatt25 Linux - Newbie 5 06-01-2001 10:08 AM


All times are GMT -5. The time now is 09:54 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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration