Thursday, July 28, 2011

Debian changing root password

Follow these instructions to boot into single user mode and change the password of root on Debian.

1) When GRUB loads press 'e'
2) Find the line with initrd and goto the end and add init=/bin/sh
3) Press Ctrl + x to boot
4) You will get a prompt with #
5) You need to remount the root filesystem in read write mode by using the command mount -o remount rw /
6) use the command passwd to set the new password.

Done!

No comments: