Sam Debruyn

Cloud Data Solution Architect

Specialized in Microsoft Azure, Fabric & modern data stack. Microsoft Data Platform MVP. Public speaker & meetup organizer. FOSS contributor.

Sam Debruyn

Natively boot Windows with a virtual HDD

2 minutes

A few days ago Microsoft released a new build for Windows 10 and I wanted to give it a try. However, I didn’t want to resize my partitions or overwrite my Windows 8.1 partition.

Well, then install it in a VM!

Then I wouldn’t have access to all of my RAM and CPU, so that wasn’t a solution either. However, I found the ideal solution.

Apparently you can install Windows in a virtual hard drive. Let me guide you through:

  1. Create a new VHD-file and remember the path to it. You can use Disk Management (run diskmgmt.msc) and click Action and Create VHD. I made it about 70 GB big with a dynamic size.
  2. Boot into the Windows installation (use Rufus or something similar to create a bootable USB stick).
  3. Select Custom: Install Windows only (Advanced), not an Upgrade.
  4. Now you have to select the partition on which you want to install Windows. Press SHIFT+F10 to open a command prompt instead.
  5. Enter diskpart to open the DiskPart utility.
  6. In DiskPart enter select vdisk file=C:\Windows10.vhd with the correct path to your VHD to select the VHD.
  7. Now enter attach vdisk and close the command prompt.
  8. If you now press Refresh you will see unallocated space on a newly added disk station, that is your virtual hard drive. Select it.
  9. You can now continue installing Windows as usual.

I was surprised to find out about this possibility. This way you can try the new Windows in full without compromising your production environment.

You might also like

If you liked this article, follow me on LinkedIn, Bluesky, or other social media to stay up-to-date with my latest posts. You might also like the following 2 posts about related topics: