Debian boot to single-user mode

One method:

  1. Append init=/bin/bash to the end of the grub line which begins with linux (and ends with quiet).

  2. Reset your password and reboot normally.

  3. Don't forget it again.

  4. Consider installing sudo.


Another method:

  1. Since this is apparently a virtual machine, you can mount its disk on another (working) virtual machine and manually remove the password from the /etc/shadow file. Or use kpartx to work with the virtual machine image file from the host or from another machine.

DEBIAN / UBUNTU root PASSWORD RECOVERY

  1. First screen - grub - press e
  2. Modify kernel line: add single between ro quiet and at the end of this line add init=/bin/bash
  3. Press F10
  4. When the prompt is root@(none):/# you have to remount the / partition to have read-write access: mount / -rw -o remount
  5. Now you are ready to modify the root password: type passwd and change it!

Good luck

P.S: try to look at the /etc/shadow file to find other users...


Your tutorial refers to Grub (legacy Grub). This is Grub2. The line beginning with linux would be the kernel line in Grub.