Skip to content

Latest commit

 

History

History
33 lines (20 loc) · 1.08 KB

HOW-TO Reset Virtualbox user password.rst

File metadata and controls

33 lines (20 loc) · 1.08 KB

HOW-TO Reset a VM user password

If you forget the user's password for a VM, the simplest solution is to restart the VM into single user mode.

Originally the fix found on this thread on AskUbuntu

  1. Reboot the VM and, during the GRUB splash-screen, hit ESC

  2. With the list of options available, hit the e key and, in the editor presented, add single at the end of a line similar to this one:

    linux /boot/vmlinux-3.13...-generic root=UUID=<uuid> ro
    

    so that it looks like this:

    linux /boot/vmlinux-3.13...-generic root=UUID=<uuid> ro single
    
  3. you will be presented with a console and the root prompt (#): use the passwd command to change your user's password:

    # passwd marco
    

If you can't even remember which user(s) were configured, the easiest way is to ls /home - or use the following:

# cat /etc/passwd | grep -e "/bin/bash$" | cut -f1 -d: | sort