8.1.2 "I forgot the root password!" (2)
Boot from any emergency boot/root disk set. If
/dev/hda3 is the original root partition, the following
will let one edit the password file just as easily as the above.
# mkdir fixit
# mount /dev/hda3 fixit
# cd fixit/etc
# vi shadow
# vi passwd
The advantage of this approach over the previous method is one does not need to
lilo password (if any). But to use it one must be able
to access the BIOS setup to allow the system to boot from floppy disk or CD, if
that is not already set.