digital adj. Having digits.     peer n. A comrade; a companion; a fellow; an associate. inmotion    
   
Recent Articles
Stop DNSMasq From Forwarding Local Hostnames
Saturday, September 25, 2010
Securing your Wireless LAN
Wednesday, August 18, 2010
Some tips and things you might not know about your wireless network.
Using Different Subversion Client Versions
Wednesday, August 18, 2010
Handling a Subversion Repository URL Change
Sunday, May 3, 2009
If your repository URL changes, you can use the following command to fix existing snapshots.
vfat Mounts Default to Lowercase Shortnames
Tuesday, April 21, 2009
I want a "this is brain-damage" quote from Linus for this mess.
VirtualBox or VMWare Virtual Machine at Login
Sunday, April 12, 2009
How to start a virtual machine in X when a user logs in.
Dialog Progress Bar Through Pipe
Sunday, April 12, 2009
How to use dialog to display a script progress bar and communicate progress to it through a named pipe.
Mount JFFS2 Image
Saturday, October 25, 2008
Example of how to mount a JFFS2 image using mtdblock.

Measuring programming progress by lines of code is like measuring aircraft building progress by weight.
- Bill Gates

Sys Admin-Linux...-Change Lost...

Change Lost Root Password

Sunday, August 22, 2004 by digitalpeer

If you have a boot loader password this isn't going to work. That requires a little bit more work. However, if you have simply lost the root password and want to change it to something you know then this is all you need to do. This simply explains how to boot into single user mode when you are sitting in front of the machine and change the root password.

LILO


At the boot screen hit CTRL-x and type "linux single" and hit enter.
It should boot to a shell and then you can simply run passwd and change the password.

GRUB


At the boot screen hit "e", select the line with "kernel" on it, hit "e" again, and add "single" to the end of the line. Press enter and then boot to a shell. From there you can run passwd and change the root password.

Drive Not Mounted


If your root partition is not mounted when you get to the shell you can run
mount -o remount,rw /

to mount it. You can verify it's mounted with the commands df or mount.
Comment Wednesday, July 22, 2009 by  by Boopathy
I got it thanks
Comment Tuesday, March 15, 2011 by  anonymous
Will this work in Fedora??? If not how to change root password in fedora linux?

Submit Comment to This Article
Please post a comment if you have something to add, find something wrong, or would like more information on the topic at hand. Do not use the comment form to contact the author about unrelated concerns!

Name: Email (optional):
Enter verification number here: