In my PC, Linux is already installed and I forgot the password. I want to recover my Linux system password. How can I do it, step by step?
|
feedback
|
migrated from stackoverflow.com Sep 14 '10 at 9:37
This question came from our site for professional and enthusiast programmers.
|
There is no way to recover a password. You can boot a different installation (e.g. from DVD), mount the partition with /etc/shadow and clear the password (set it to the empty string). You can also try to run a password cracker on the file if you really need to know what it was. | |||||||
feedback
|
|
From the boot loader, instead of The system will boot up as usual but drop you to a Bash prompt never asking you for a password and already having mounted the system as rw. Then reset your password with the passwd command. When you're done run
for CLI startup or
for GUI. No mounting, remounting, rebooting, booting from live CDs or distributions are needed when done. | |||||||
feedback
|
|
Fastest way is to pass the parameter Second option (since nowadays linux distro need a ramdisk with drivers when they start) is to boot with a live distro, then mount your linux partition somewhere (a-la If you find this complicated learn the lesson: (1) don't use root (2) don't use root (3) use sudo | |||
feedback
|
|
Your system password? Do you mean the root password? Assuming you still have your password and you are in the sudoer list, you can set a new root password by running
| ||||
feedback
|