I run Ubuntu in a virtual machine and I've managed to reset my password in recovery mode, by editing the parameters according to these instructions on Superuser.com. Summarizing my steps:
I changed ro single at the end of the line beginning with Linux to rw init=/bin/bash, while booting, then using the command passwd <username>, entered the new password twice. The password is reported to be updated successfully.
However, when I try to reboot the system nothing happens. I tried the command reboot, but it does not work. If I type exit I get kernel panic.
Any tips on how to proceed?
41 Answer
Try telinit 6 you don't need sudo since your in single user mode.
EDIT:
If it wont reboot using the standard tools there is a way to do it straight through to the kernel, however this does not close file systems nicely.
Found this here
5you must activate the magic SysRq option:
echo 1 > /proc/sys/kernel/sysrqWhen you are ready to reboot the machine simply run the following:
echo b > /proc/sysrq-triggerThis does not attempt to unmount or sync filesystems, so it should only be used when absolutely necessary..