Linux – How to boot RHEL5 into failsafe mode from GRUB

failsafegrublinux

I'm locked out of a Red Hat Linux 5 machine and need to "break in" to reset the root password. I've done this before by interrupting GRUB and putting the machine in failsafe to get to root, but I can not remember the details. Once I stop GRUB, what do I do?

Best Answer

Booting:

  • Use the arrow keys to select the kernel to boot
  • Hit e to edit the command line
  • Append init=/bin/bash to that line and hit Enter
  • Hit b to boot

Once booted:

  • mount -o remount,rw /
  • passwd