VMmanager 6: Administrator guide

How to reset password on a Windows VM?


You can reset the administrator password on a virtual machine (VM) with a Windows operating system (OS). The password is reset in the recovery mode. 


Performing these actions may cause the OS to malfunction.

Example of resetting the password in Windows Server 2019

  1. Set the VM to recovery mode: Virtual machines → select the VM → menu Recovery modeStart mode and reboot.
  2. Wait until the recovery mode is started and connect to the VM via VNC: Virtual machines → select the VM → menuVNC.
  3. After booting SystemRescueCD, mount the Windows partition:
    1. Enter the command to display all partitions:

      fdisk -l
       The result of the command execution

    2. Mount the required partition:

      mount /dev/vda2 /mnt
       Comments to the command

      /dev/vda2 — partition with Windows

  4. Go to the directory with the system configuration files:

    cd /mnt/Windows/System32/config/
  5. Display the list of Windows users:

    chntpw -l SAM
     The result of the command execution

    RID — account ID

    Admin? — is the user the administrator?

  6. Run the chntpw utility to reset the password:

    chntpw -u 0x01f4 SAM
     Comments to the command

    01f4 — administrator account ID

  7.  If the account is locked, the utility menu will contain the item "2 — Unlock and enable user account (probably locked now)". In this case enter "2" to unlock the account.
  8. Enter "1" to reset the account password.
  9. Enter "q" to exit the utility and "y" to save the changes made.
  10. Check the result of the utility actions:

    chntpw -l SAM
     The result of the command execution

    The "BLANK" status for the Administrator user means that the password has been reset.

  11. Disable the VM's recovery mode: Virtual machines → select the VM → menu Recovery modeDisable mode and reboot.

Thank you for your feedback!
Was the article useful?
Tell us why not:

it does not match the title

it was hard to understand

I didn't find the answer

recommendations from the article did not help


Tell us what you didn't like in the article: