View Single Post
  #2 (permalink)  
Old 2008-02-29
Danielpb Danielpb is offline
Senior Member
 
Join Date: 2006-10-23
Posts: 163
Rep Power: 2
Danielpb has an average reputation (10+)
Default Re: password recovery on R61

I came accoss this but not 100% it will work....

==========================

boot from a live linux cd, mount up the / partition and edit the /etc/shadow file and removing the root password method myself.

An example mount command once you boot from the cdrom (your root device may be different):
mount -o remount,rw /dev/sda8 /mnt

Just edit /mnt/etc/shadow to remove the password field: move to just beyond the first ":" and remove everything up to the next ":". With vi, that would be "/:" to move to the first ":", space bar once, then "d/:" and ENTER. You'll get a warning about changing a read-only file; that's normal. Before you do this, /mnt/etc/shadow might look like:

root:$1$8NFmV6tr$rT.INHxDBWn1VvU5gjGzi/:12209:0:99999:7:-1:-1:1074970543
bin:*:12187:0:99999:7:::
daemon:*:12187:0:99999:7:::
adm:*:12187:0:99999:7:::

and after, the first few lines should be:

root::12209:0:99999:7:-1:-1:1074970543
bin:*:12187:0:99999:7:::
daemon:*:12187:0:99999:7:::
adm:*:12187:0:99999:7:::

You'll need to force the write: with vi, ":wq!". Then reboot and eject the cd and try accessing expert with a blank password
Reply With Quote