Link to home
Start Free TrialLog in
Avatar of rsable
rsable

asked on

Lost root passwd

What will you do if you forgot your ROOT PASSWD?
I've mounted the PASSWD file but it is in read-only mode.
 
Avatar of rbr
rbr

How did you mount the password file?
To remove the root password to the following.

Boot Linux from disc and enter with root (not password needed). Mount the drive where the system is on. Enter the etc directory and edit the file passwd. Clear the password entry for root. Reboot your system.
Avatar of rsable

ASKER

I tried booting using the disc after that happened, i mounted the passwd using  mount <dev> <file/directory>, but i can't find a way to edit the passwd file -- pico, edit and joe didn't work.Is there another way I can't modify the passwd file?  is there an  equivalent function that works like edit or pico?
ASKER CERTIFIED SOLUTION
Avatar of wqclatre
wqclatre

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
You can also try this:
1. boot from floppy
2. mount youre / partition on /mnt
3. Use chroot to change / to /mnt
4. Try vi or pico or some other editor now.


Use vi!

Avatar of rsable

ASKER

thanks....salamat!