[TAG] Please help me! I lost my root password

Peter Knaggs peter.knaggs at gmail.com
Thu Nov 17 21:49:18 MSK 2005


On 11/17/05, ANDREI <me190k at yahoo.com> wrote:

> I recently changed my root password and my root password would not work
> anymore.

A friend of mine recently had a similar lost
root password for Debian, and we used the method
described here:

http://www.penlug.org/twiki/bin/view/Main/GrubSecrets

... append the following to grub's kernel line
(you may need to press "Esc" to leave the graphical
 boot screen, to get to the real grub command line),
 by using the e key to edit.
 Add the following:

   init=/bin/bash

This will start a shell without starting any daemons
or other stuff. It replaces the init process with a
shell. If the system shutdown was clean, you should
then be able to re-mount the root filesystem
read-write, for example to reset a forgotten root
password, using:

  mount -o remount,rw /

Once you have the root filesystem mounted read/write,
you can use the "passwd" command to change the root
password, as you are already root.

Hope it helps,
Peter.





More information about the TAG mailing list