0

I create a VM with a VHDX. I write some txt files in C:\LocalFiles. If I turn off the VM using Stop-VM and restart it, the files are still there. The problem arises when I run C:\Windows\System32\sysprep\SysPrep.exe /generalize /oobe /shutdown The VM shuts down after 3 or 5 seconds.

If a go to the VHDX (not the AVHDX with a GUID name) and mount it, those txt files are gone! Those files are created before long before Syspreping.

What I think is happening is that the VHDX is being restored to an earlier state. If I go to Hyper-V to start the VM again, this pops up. Clicking continue, starts the VM and asks for a new password (because it was sysprepped.) I then right click in Hyper-V manager and turn VM off. Then manually mount the VHDX and surprise the files are there!!!

What's going on there? and how to mount the VHDX after sysprep and still find the files?! Why do I need to start the VM again and click continue for the VHDX to have latest changes?

enter image description here

noobie
  • 101
  • 1

0 Answers0