my buddy forgot his root password (single home desktop) is there a way for him to get it back? or should he just rebuild his system?
Printable View
my buddy forgot his root password (single home desktop) is there a way for him to get it back? or should he just rebuild his system?
Boot off a LiveCD, mount the root (/) filesystem, delete the encrypted root password out of /etc/shadow.
Reboot and boot off the HDD. The root account will not have a password.
Or
Boot up in Single User Mode and execute passwd command. Assign new root password. It wont ask of earlier password. ;)
how do i boot in single user mode?
Man, I never use single user mode except in Solaris....and that requires the root password. I *never* remember this for Linux...
Google => Linux Single User Mode PasswdQuote:
how do i boot in single user mode?
:shock: i feel like my computer is naked after reading that rticle
I felt the same way after discovering how easy it was to reset the root password. Many people set a password for the bios and for grub to increase the security, butI think if anyone has physical access to your machine, they can always find ways to compromise it if they wish.
Another good one just to round out the field:
Upon boot edit the boot options:
For LILO
"linux init=/bin/bash"
or add it to the Grub "kernel" line
It will give a prompt earlier at which you can use passwd for root. (after remounting -rw)