LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 04-08-2007, 12:52 PM   #1
Pumalite
Member
 
Registered: Apr 2007
Location: All over
Distribution: Suse 10.2
Posts: 131

Rep: Reputation: 15
Suse 10.2 locked me out as user or root


Up to now Suse had been loggin automatically. Today, it presented the first screen demanding username and password. I tried as a user first ( which I know quite well, both, username and password)Well, it rejected me. I tried then as root ( which I also know quite well) and it rejected me too. I've been reading and found hints at a full disk( it's not), I also found references to Failsafe, but I dont know how or when to use it. As of now I'm completely locked out of Suse. Help please! What can I do other than reinstall?
 
Old 04-08-2007, 01:04 PM   #2
johngreenwood
Member
 
Registered: Nov 2006
Location: Lancashire, United Kingdom
Distribution: Slackware 13
Posts: 243

Rep: Reputation: 31
Have you changed anything which may have caused this?
Also, have you tried to login to a terminal?

The 'failsafe' mode should be on the GRUB screen, and there is also a 'failsafe' mode in the sessions tab/button on the login screen.
 
Old 04-08-2007, 02:30 PM   #3
Valkyrie_of_valhalla
Member
 
Registered: Jan 2006
Location: Romania
Distribution: Suse 12.0, Slackware 12.1, Debian, Ubuntu, Gentoo
Posts: 301

Rep: Reputation: 30
I'd suggest getting a live cd distro, such as knoppix, and checking your /etc/passwd /etc/group and /etc/shadow files...
There, you can add a new user, put it in the root group, and change the passwords of the other users. If you need an explicit howto, just tell me, but I'm sure there are numerous howto-s out there.
 
Old 04-08-2007, 02:52 PM   #4
Pumalite
Member
 
Registered: Apr 2007
Location: All over
Distribution: Suse 10.2
Posts: 131

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by Valkyrie_of_valhalla
I'd suggest getting a live cd distro, such as knoppix, and checking your /etc/passwd /etc/group and /etc/shadow files...
There, you can add a new user, put it in the root group, and change the passwords of the other users. If you need an explicit howto, just tell me, but I'm sure there are numerous how -s out there.
Thanks a lot guys¡ The problem I have now is that following someone elses advice I booted into 'rescue mode', but the screen for GRUB doesn't want to show up; instead it takes me back to suse with 'rescue login:'which doesn't accept me as anything. I will try the Live CD idea first.
 
Old 04-08-2007, 02:56 PM   #5
Pumalite
Member
 
Registered: Apr 2007
Location: All over
Distribution: Suse 10.2
Posts: 131

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by johngreenwood
Have you changed anything which may have caused this?
Also, have you tried to login to a terminal?

The 'failsafe' mode should be on the GRUB screen, and there is also a 'failsafe' mode in the sessions tab/button on the login screen.
Thanks for the reply. Can you explain to me the Failsafe and the 'sessions/tab/button' please? I need more detail because I'm totally new to this.
 
Old 04-08-2007, 03:48 PM   #6
Pumalite
Member
 
Registered: Apr 2007
Location: All over
Distribution: Suse 10.2
Posts: 131

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by Valkyrie_of_valhalla
I'd suggest getting a live cd distro, such as knoppix, and checking your /etc/passwd /etc/group and /etc/shadow files...
There, you can add a new user, put it in the root group, and change the passwords of the other users. If you need an explicit howto, just tell me, but I'm sure there are numerous howto-s out there.
I kicked in Ubuntu but I don't know how to get to the files of suse. I need more detailed explanation, 'how-to or step by step. Sorry to bother you is just that I hate to reinstall because I had the hard drive already full of stuff.
 
Old 04-08-2007, 04:49 PM   #7
Pumalite
Member
 
Registered: Apr 2007
Location: All over
Distribution: Suse 10.2
Posts: 131

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by Pumalite
I kicked in Ubuntu but I don't know how to get to the files of suse. I need more detailed explanation, 'how-to or step by step. Sorry to bother you is just that I hate to reinstall because I had the hard drive already full of stuff.
BTW, when I go into ´sessions> Failsafe, the system does not respond; stays in the same old blue screen asking for username and password.
 
Old 04-08-2007, 06:21 PM   #8
Valkyrie_of_valhalla
Member
 
Registered: Jan 2006
Location: Romania
Distribution: Suse 12.0, Slackware 12.1, Debian, Ubuntu, Gentoo
Posts: 301

Rep: Reputation: 30
New easyer idea: reset the root password.
Note: I never actually did this, but, from the manuals, it should work.
Type "mount" in a console and it will show you where each partition is mounted. The display should be something like
/dev/hda1 mounted on /mnt/hda1
That means that the first partition on the hard disk set up as primary master is mounted in the folder /mnt/hda1.
The files should be in there.
I guess you need root to access the files. You can use "sudo".
I don't know what text editor comes with ubuntu, check in the menu to see what applications it has. Anyway, let's call it texteditor (replace this with the lowercase app name you find there). You just type in "sudo texteditor" in a console and it should open the editor with root privileges.
Make a backup of the 2 files (in case I made a mistake here) type in a console:
"sudo cp /mnt/hda1/etc/passwd /mnt/hda1/etc/passwd.old"
"sudo cp /mnt/hda1/etc/shadow /mnt/hda1/etc/shadow.old"
Open /mnt/hda1/etc/passwd. You should find an entry something like:
"root:x:0:0::/root:/bin/bash". What you have to do is remove the x ( "root::0:0::/root:/bin/bash").
Open /mnt/hda1/etc/shadow. You should find something like "root"$als2rha2sa1&*4dsf2#4$:13513:0:::::". The long mixture of characters is your encrypted password. I think you have to delete that too, make it something like ""root::13513:0:::::"
Now, the root user on suse should be passwordless and should allow you to log in. Reboot and try to log into suse as root with an empty password.

If it doesn't work, copy the backup files back, and wait for new suggestions.
Good luck.

Edit: here's a more in depth tutorial: http://linuxgazette.net/107/tomar.html
Just found it searching on the forum.

Last edited by Valkyrie_of_valhalla; 04-08-2007 at 06:25 PM.
 
Old 04-08-2007, 08:36 PM   #9
Pumalite
Member
 
Registered: Apr 2007
Location: All over
Distribution: Suse 10.2
Posts: 131

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by Valkyrie_of_valhalla
New easyer idea: reset the root password.
Note: I never actually did this, but, from the manuals, it should work.
Type "mount" in a console and it will show you where each partition is mounted. The display should be something like
/dev/hda1 mounted on /mnt/hda1
That means that the first partition on the hard disk set up as primary master is mounted in the folder /mnt/hda1.
The files should be in there.
I guess you need root to access the files. You can use "sudo".
I don't know what text editor comes with ubuntu, check in the menu to see what applications it has. Anyway, let's call it texteditor (replace this with the lowercase app name you find there). You just type in "sudo texteditor" in a console and it should open the editor with root privileges.
Make a backup of the 2 files (in case I made a mistake here) type in a console:
"sudo cp /mnt/hda1/etc/passwd /mnt/hda1/etc/passwd.old"
"sudo cp /mnt/hda1/etc/shadow /mnt/hda1/etc/shadow.old"
Open /mnt/hda1/etc/passwd. You should find an entry something like:
"root:x:0:0::/root:/bin/bash". What you have to do is remove the x ( "root::0:0::/root:/bin/bash").
Open /mnt/hda1/etc/shadow. You should find something like "root"$als2rha2sa1&*4dsf2#4$:13513:0:::::". The long mixture of characters is your encrypted password. I think you have to delete that too, make it something like ""root::13513:0:::::"
Now, the root user on suse should be passwordless and should allow you to log in. Reboot and try to log into suse as root with an empty password.

If it doesn't work, copy the backup files back, and wait for new suggestions.
Good luck.

Edit: here's a more in depth tutorial: http://linuxgazette.net/107/tomar.html
Just found it searching on the forum.
Thanks again for your prompt reply. Let me tell you what I have learned so far and what I´ve done. Another guy, in another forum told me to log in as´single´ from the GRUB screen, which worked, up to a point. I did manage to change the password with this method, but when I tried it, it did not work. Someone told me that in username ( in regular bootup), I should write ´root´ instead of my regular log in name. I've not tried that yet, but if it doesn't work, I'll try your advice and let you know ASAP.
 
Old 04-08-2007, 09:36 PM   #10
TigerLinux
Senior Member
 
Registered: Sep 2005
Location: Kuala Lumpur, Malaysia
Distribution: Ubuntu 11.04
Posts: 1,731

Rep: Reputation: 30
Suse 10.2 sucks! Try the 10.3 alpha 1, it is ok, no such stupid problem!
 
Old 04-09-2007, 05:02 AM   #11
Pumalite
Member
 
Registered: Apr 2007
Location: All over
Distribution: Suse 10.2
Posts: 131

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by TigerLinux
Suse 10.2 sucks! Try the 10.3 alpha 1, it is ok, no such stupid problem!
Hi guys! Tried the single user mode; changed the password at the log in. Rebooted and at the old blue screen I typed ´root´ as username and then the new password. That took me right in. Went to the terminal and changed the password of the common user. It said ´Password Changed´, so I rebooted and tried to enter as the common user with the new password. It didn't take it, so I'm back in as root, but it's too dangerous! I have to learn how to assign a new user and a new password. Can you help me with that? Thanks in advance.
 
Old 04-09-2007, 05:54 AM   #12
Valkyrie_of_valhalla
Member
 
Registered: Jan 2006
Location: Romania
Distribution: Suse 12.0, Slackware 12.1, Debian, Ubuntu, Gentoo
Posts: 301

Rep: Reputation: 30
If you're in, you should have the command "useradd" in the console. If you have KDE, you might also have kuser, which is a nice graphical interface for this, but... it frequently gives me errors, so I wouldn't recommend it. Alternatively, you could also manually edit /etc/passwd and /etc/groups.

BTW, how did you change the password for the common user? With "passwd oldusername"? If that doesn't work, then something really weird is happening...
 
Old 04-09-2007, 05:59 AM   #13
TigerLinux
Senior Member
 
Registered: Sep 2005
Location: Kuala Lumpur, Malaysia
Distribution: Ubuntu 11.04
Posts: 1,731

Rep: Reputation: 30
i just want to make sure my userid and password is recognised, any remedy?
please teach me step by step.
 
Old 04-09-2007, 07:41 AM   #14
Pumalite
Member
 
Registered: Apr 2007
Location: All over
Distribution: Suse 10.2
Posts: 131

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by TigerLinux
i just want to make sure my userid and password is recognised, any remedy?
please teach me step by step.
Are you Inside the system or locked out?. If you are inside follow Valkyrie´s advice. If you are locked out: boot as a ´single´ user from the GRUB screen. That will take you right in. At the prompt, type ´passwd´, change your passwoed and reboot. At the old blue screen, type ´root´ as the username, then your new password; that will take you right to your Desktop. Remeber you are root and have to change that. Then, follow Valkyrie´ advice. After you have added a new user and password, log out and log in again as the common user. I have not had yet time to try it(Valkyrie´s advice), but I think that is how it works.
 
Old 04-09-2007, 12:24 PM   #15
Valkyrie_of_valhalla
Member
 
Registered: Jan 2006
Location: Romania
Distribution: Suse 12.0, Slackware 12.1, Debian, Ubuntu, Gentoo
Posts: 301

Rep: Reputation: 30
Quote:
Originally Posted by TigerLinux
i just want to make sure my userid and password is recognised, any remedy?
please teach me step by step.
Hmm, I don't really understand the question.
To make sure your userid and password is recognised, you just have to log in and check...
If you are already in and don't want to log out, you can use "su":
su username
A "password:" prompt will appear (unless you are logged in as root), and this is the simplest way to check if it's recognised.
 
  


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
Locked myself out of mysql...root user db table destroyed organica Linux - Server 2 12-08-2006 10:35 AM
Im the only user on SUSE 10.0 and it will not allow me in the root folder BFGeier Linux - Newbie 4 01-02-2006 07:09 AM
SuSE 9.1 'Switch User' when screensaver is locked Cichlasoma Linux - Distributions 1 07-20-2004 07:49 AM
Scanner to work as USER and not forced as ROOT Root (Suse 9.1) 1kyle Linux - Hardware 0 07-10-2004 08:51 AM
Can't login as non-root user in SUSE 9.0 blue_blood Linux - Newbie 3 02-12-2004 03:13 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 08:00 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