Avatar of Wolf
Wolf
Flag for United Kingdom of Great Britain and Northern Ireland asked on

How do you increase the HDD on a Virtual Machine?

I am running VMware Server on a Windows Server 2003 machine.

I have one Virtual Server setup with a single Virtual Hard Drive of 25Gb.  This Virtual Server, when booted splits the Hard Drive into two partitions:
C$ = 15Gb
D$ = 10Gb

The D drive is almost full and i need to increase it.  How do i go about increasing the size of the Virtual Hard Drive and then increasing the partition?

Thanks
Andrew
VMwareMicrosoft Virtual ServerWindows Server 2003

Avatar of undefined
Last Comment
Wolf

8/22/2022 - Mon
vmwarun - Arun

What is your Guest Operating System ? What type of disks are you using inside your guest (Basic or Dyanmic Disks) ?
antony_kibble<!-8D58D5C365651885FB5A77A120C8C8C6-->

Okay first thing to do is to check the VMDK (virtual machine disk) integrity. I chose to run checkdisk within my Virtual Machine. You'll need to reboot and the disk will be checked before the machine starts.

Once you're happy with the integrity of your disk its time to expand it. Using vmware-vdiskmanager. You must power the machine off first in VMWare workstation or VMWare Player.

Navigate to your VMWare folder and issue the following command from the command prompt, passing -x to increase the size followed by the new size (e.g. 20Gb), followed by the path to the vmdk file you want to resize.

C:\Program Files\VMware\VMware Workstation\vmware-vdiskmanager -x 20Gb "d:\VM Folder\vmdiskfile.vmdk"

This will take some time, and once complete the application will give you some sizing messages.

Now you need to expand the capacity of the disk to take advantage of its new size. If the disk is the system volume you will need to mount the disk in a second VM and expand it from there. If its not a system volume do it within the virtual machine it belongs to.

Once you've mounted the disk in a different VM or booted up the VM it belongs to if its not the system volume, do the following.

Go to the command line and start the diskpart utility. By issuing the following command.

diskpart
Once you've started diskpart, list the drives using the following command:

list disk
This will show you the disks assigned to your machine. Now the important command

list volume
This will show you the drives, their volume number, capacity etc. You now need to select the volume you are about to expand, using the following command. Where n is equal to the number of the volume.

select volume=n
Once selected, you can now expand it using the extend command. You can optionally specify the amount extend it by.

extend
That's it.

Once you've extended the disk, it's wise to defrag the drive. If you use the defragment tool in VMWare workstation you will find it much quicker than deframenting the drive from within the machine.
Wolf

ASKER
Thanks very much, that sounds fairly simple but i think it might take a while.
One quetion though...
It's a single Hard Drive with a size of 25Gb, which is then partitioned into a system volume (c) and a storage volume (d).  Because its a system volume would that mean i would have to mount it on a seperate virtual machine?  How do i do that?
Thanks
This is the best money I have ever spent. I cannot not tell you how many times these folks have saved my bacon. I learn so much from the contributors.
rwheeler23
Wolf

ASKER
Oh, and its VMware Server, not Workstation, does that make any difference?
antony_kibble<!-8D58D5C365651885FB5A77A120C8C8C6-->

First question - don't know, sorry.

Second question - No.

Wolf

ASKER
Do you knkow if its possible to just create a second Hard Drive for the virtual machine?  I could then just partition that as "E" and point the data to it
If i could add a second hard drive that would be a lot easier, but can't see the options in VMware server
⚡ FREE TRIAL OFFER
Try out a week of full access for free.
Find out why thousands trust the EE community with their toughest problems.
ASKER CERTIFIED SOLUTION
OxygenITSolutions

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
vmwarun - Arun

You can add a new virtual disk to the Virtual machine and make it E:/.
The option would be available under Add New Hardware Wizard (am not sure of the Menu placement but I think that you can right click on the VM Properties Window and achieve the same).
Wolf

ASKER
I'm going to try using the convertor to clone the virtual machine and increase the drive sizes at the same time - thanks for the help
You can't just add a new virtual disk when you are using VMware Server, only in Workstation and with ESXi/Sphere
vmwarun - Arun

Check out Page 144 of this doc - http://www.vmware.com/pdf/vmserver2.pdf
It says a New Virtual Disk can be added using VMware Server.
I started with Experts Exchange in 2004 and it's been a mainstay of my professional computing life since. It helped me launch a career as a programmer / Oracle data analyst
William Peck
juliusblash

Try going into edit setting and increasing the size of the drive you want to increase and then using ExtPart or GParted to increase to size of the partition in the guest OS.

ExtPart - http://support.dell.com/support/downloads/download.aspx?c=us&cs=19&l=en&s=dhs&releaseid=R64398&formatcnt=2&fileid=83929

GParted - http://gparted.sourceforge.net/
Wolf

ASKER
VMware converter worked great!

I just shut the virtual machine down, used convertor and was able to increase the size of both partitions.

It only took 30 minutes :)