I have a Microsoft Virtual PC hard drive (.vhd format) that's maxed out at 16GB. What would be the best way to increase this disk space?

Booting into the machine (Windows XP Professional) and using the disk management snap in, I can see that the virtual drive has approximately another 40GB unused space. Trying to use diskpart, I find out that Windows XP can't extend the boot partition.

Example disk space:

enter image description here

Note: the virtual hard drive is running on Windows 7 using XP Mode.

3 Answers 3


With the VM turned off, attach the virtual hard disk VHD file by doing:

Right-click "My Computer" > Manage > Storage, right-click "Disk Management" and choose "Attach VHD".

You should now be able to resize the virtual disk as if it was a local disk.


  • Will I be able to extend the partition? right now the partition is sitting at 16 gigs out of an available 60 gigs. From my understanding, extending the partition isn't something that is built into windows.
    – Chris
    Mar 8, 2010 at 15:00
  • @Chris: I don't have Win7 to play with, but that's indeed what the MS documentation claims.
    – harrymc
    Mar 8, 2010 at 16:24
  • Outstanding. @HarryMC - yeap, this worked just like a partition magic tool would work. Walks you through a three step wizard and allows you to add space either through extending the partition or adding another VHD to the existing one. Learn something new about 7 every day.
    – Chris
    Mar 8, 2010 at 17:40
  • To unmount right click on the disk header in Disk Management an choose "Unmount VHD") digitalcitizen.life/… Jan 18, 2016 at 10:21

If I recall correctly, Virtual PC 2007 comes bundled with an application to resize VHD files. I'm not sure if VPC 2009 does, but if not, you can download v2007 for free from Mcft's website/


Shut down the virtual machine and go to its settings/configuration panel. When it's running certain things cannot be configured like hard disk size, RAM allocation, etc.

If it's a limitation of the product enforced on per disk size try added a second virtual disk.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.