Single User Mode in Suse Linux 10.1 - Reset root Password?

compgeek

Junior Member (25+)
hI FRIENDS

How to enter Single user mode in linux using GRUB and LILO
I read in a book that when the boot menu appears one has to select the linux os and type E and hit enter to get the command prompt where root password can be changed

But when i tried this in suse 10.1 [grub boot loader] i didnt get the command prompt
it directlly entered guI

Can any one tell me the way to enter single user mode in linux in detail

BYeeeeeeeeeee
 


So you followed the steps to rest the password correctly. Let me make sure once more.

1. At the GRUB boot menu select the linux option and press 'e' .

2. Choose your kernal and press 'e' once more.

3. Here in the Edit mode add the following to the end of the line leaving a space.


or


4. Press ENTER to exit the edit mode. Once back at the GRUB screen, press 'b' to boot into single user mode.

5. This will make you the "root" user without asking for a password. Once the system has booted, you can change the root password using the password command in the command prompt:

 
Reset Root Password - Another Complex & Risky Method

If the easy method doesn't work on your machine, another way to solve the "lost root password" problem is to boot your computer from your Linux Installation CD, or from a live-CD such as Knoppix.

Using Knoppix, boot the live-CD then go to a terminal and su to root (no password is required) then issue the following commands (be sure to replace each /hda1 with your own root partition device):

mount -o dev,rw / mnt/hda1
cd / mnt/hda1/etc

Once you are into your system / etc directory, you can use a text editor to edit the / etc/shadow file where the password is stored.

Various information about root and user accounts is kept in this plain-text file but we are only concerned with the password portion.

For example, the / etc/shadow entry for the "root" account may look something like this:

root:$1$aB7mx0Licb$CTbs2RQrfPHkz5Vna0.fnz8H68tB.:10852:0:99999:7:::

Now, using your favorite editor delete the password hash. For this example, the actual password is in red text and is all those characters between the 1st and 2nd colons.

vim shadow


After you've edited this field, it should look like this:


root::10852:0:99999:7:::


Now save the file and change back to the root directory and unmount the system root partition (don't forget to change the /hda1) as follows:


cd /
umount / mnt/hda1

Now reboot the computer.

Once the computer has booted and you're at the login prompt, type "root" and when asked for the password just press ENTER (entering no password). After a successful login, you need to set the new password for root using the following command:



Hope this helps..
 
I've installed SUSE 10.1 yesterday. It seems the Edit option in GRUB is disabled. So try the second method.
 
Hello all,

When I try the command #mount -o remount,rw / it was executed successfully but when I type passwd it is throwing me an error message “passwd: user not known to the underlying authentication module” Please guide me on what to do next.

Regards,
Blue
 
Of course if you are using some old SuSE versions like 9, then when you boot with the
boot option, choosing "Linux".
Then you need only type
for the login/username and no password.
Then type
at the shell prompt and reset, reboot and you are back in business.
if that doesn't work use Strider's second choice and again, no password is needed at the X login for root.

Have FUN with it!
 

Back
Top