How To Resize VHD To Get More Space for Your Virtual Machine

3

If you use Microsoft Virtual PC enough, you eventually may end up storage shortage on VHD you originally created. And when it happens, all you need to do is extending the VHD to get more space from the physical hard drive, as long as you have enough space left in there.

Unfortunately, Windows Virtual PC doesn’t have this feature built-in that allows you to extend your VHD. However, there are quite a few tools out there that can do that. And most of them are FREE and do the job quite well.

Resizing the VHD file

VHD Resizer from VMToolKit is one of them that does the job quite well with an easy-to-use user interface. Not only does it resize VHD files, but it also converts between Fix and Dynamic file type as well. It’s a sector by sector copy operation from one size/type to the other and keeps the source VHD file unaltered.

Simply launch the program, point to where the source VHD file is, where the new VHD file will be saved, and specify the type of file type and the new size of the VHD file, and click Resize button to start.

image

image

If you select Dynamic, the physical size of the VHD file will remain the same after you have done resizing.

Now, either swap the VHD file name or create another Virtual Machine profile to use the new extended VHD image file.

VHD Tool from Microsoft MSDN is another tool that does the job well but without a GUI. You will need to open Dos Command to use the tool. It is an unmanaged command-line tool that provides useful VHD manipulation functions, including creating a VHD, converting an existing RAW disk image file to a fixed-format VHD, repairing a broken Hyper-V snapshot chain, and extending an existing fixed format VHD to a large size.

image

Note that if your VHD is dynamic, this tool isn’t for you. Try the first one instead.

Extending disk volume

Extending the VHD file is just the first step in the process. Now we need to extend the disk volume in the VHD to use the extended space. It’s a lot easier doing this in Windows 7, thanks to the new disk management feature that allows you to extend the volume right in the disk management tool.

First to attach the new extended VHD file in Disk Management.

image

Make sure the Read-Only option is not checked.

image

image

Right-click the Active Volume and choose Extend Volume, which brings up Extend Volume Wizard.

image

Click Next, select the amount of space you want to extend, and click Next again, and Finish.

image

A volume that uses up all the available space in VHD file is ready for you.

image

De-attach the VHD file before booting it up.

image

All set. Now you have a Virtual PC running with more space in it.

SHARE

3 COMMENTS

LEAVE A REPLY

Please enter your comment!
Please enter your name here