Microsoft Virtual PC
An article from Pieter's Knowledge Base
Table of Contents
Disclaimer
What is Microsoft Virtual PC?
Pricing
Where to download?
Resizing A Virtual Disk
Disclaimer
All information on this page is provided
on an as-is basis with no warranty of any
kind. Using this information is at your own
risk. In no case I will be held liable for
any damages resolving from using this page.
What is Microsoft Virtual PC?
Virtual PC is a program by Microsoft that
runs within Windows and can run another operating
system (Windows or any practically any other
operating system that can run on an x86 PC).
This is handy because it allows you to test
operating systems and software without making
changes to your main operating system. It
also allows you to run programs that require
old operating systems on newer operating
systems.
Virtual PC itself is a free product, but
you will need to have a license for each
operating system you install in a so-called
virtual machine.
Where to download?
Virtual PC can be downloaded from the Microsoft
web site:
http://www.microsoft.com/virtualpc
Resizing A Virtual Disk
Once you have created a virtual disk (and
possibly installed an operating system on
it), its maximum size is fixed, even if it
is a dynamically expanding disk. So if the
virtual disk has a maximum size of 10 GB,
it will never grow beyond that size, and
Virtual PC itself is not capable of resizing.
There is, however, a way around it, which
we will go through step by step.
Note: this procedure only works with virtual
machines running Windows 2000, Windows XP,Windows
Server 2003 and Windows Vista.
Resizing the disk using VHD Resizer
The first step to perform, is to resize the
virtual disk using a free tool named VHD
resizer. You can download it from:
http://vmtoolkit.com/files/folders/converters/entry87.aspx
- After installing it, start it from the start
menu: Start / All Programs / vmToolkit / Vhd Resizer
- First, you will be asked to provide the file
name of the virtual disk to be resized:
- Next, provide a name for the resized vhd
file (Vhd Resizer will create a new file,
not replace the existing one, which is
convenient,
since we will need the original one later):
- In the above dialog, also specify the type
of virtual disk (dynamically expanding or
fixed size) and a maximum size.
- Next, click the resize button to start the
resizing process. Once completed, you will
be notified by a message box.
Expanding the partition on the Virtual Disk
After you have resized the disk with Vhd
Resizer, the partition (drive) on it will
still be the same old maximum size, and not
grow when it needs to! So we need to resize
the partition as well.
As is clear from the example above, we now
have two virtual drives:, the old one and
the new one. It is convenient that we still
have the old one, since we can use it to
work on the new one:
- Start the Virtual PC Console, select the
virtual machine for which we want to resize
the virtual disk, and click the settings button:
- Select an unoccupied hard disk, e.g. Hard
Disk 2 as indicated in the window above.
- Click the Virtual Hard Disk File radio button, followed by the Browse button to select the new virtual disk file:
- We now have a virtual machine that boots
from the old virtual disk, but also provides
access to the new virtual disk. Click the
OK button to close the Settings window.
- Start the Virtual Machine.
- In the virtual machine, start Computer Management (either by right-clicking the My Computer icon and selecting Manage, or by selecting the Computer Management icon in the Administrative tools menu, if you have that one enabled).
- In Computer Management, click the Disk Management icon. You should see two hard drives, one
with unallocated space available:
- In the example above we have two drives:
- Disk 0, which is the system we booted from and
shouldn't make changes to!!
- Disk 1, which is the drive we need to resize. Write
down the name of this drive (in this example:
"Disk 1")
- Close Computer Management.
- Start a command line prompt by clicking Start
/ Run, and typing CMD and pressing the Enter key:
- We now have a command window. Type "diskpart"and press the Enter key:
- At the DISPART prompt, type "List disk" (+Enter) to list all available drives.
We should see the same drive names we saw
in Computer Management:
- In our example, we need to work on Disk 1,
so we make it the active disk by typing
Select Disk 1 (+Enter):
- Now we need to find out what partitions are
on this disk. Type Detail Disk (+Enter):
- The listing shows us this disk has one volume
named Volume 2. We need to select it, so we type Select Volume 2 (+Enter):
- Finally we proceed to increasing the size
by typing Extend (+Enter). The volume will now be resized
to the maximum available size:
- We can now exit Diskpart by typing Exit (+Enter)
and the command window as well by typing
Exit (+Enter) once more.
- Verify that the partition has indeed increased
with Disk Management:
- You can now shut down the virtual machine,
change the settings so that the new virtual
disk is the disk the machine is booted from.
Enjoy your new virtual disk size!
© 2007 Dutch Alps/Pieter Mol