Reducing VMWare Virtual Machine Disk space usage

I have a 250GB hard drive which I run two virtual machines off of. I received a disk space warning the other day and decided to look into the issue. One virtual machine, is taking up 140GB on the physical hard drive, but when running the only virtual disk is only 48GB used.

How can I reduce the size of the virtual disk to back around the actual size of the data (48GB)? Any other ideas on reducing the size of this huge VM?

I tried Defrag and Shrink, but shrink needs the same size as the VM in free space to shrink. I come up a few GB short.

I do have another empty 250GB hard drive to write to if that helps.

I am using VMWare Workstation 6.0.3 to run Windows XP on a Windows Vista (x64) machine.
aiscomAsked:
Who is Participating?
 
aiscomConnect With a Mentor Author Commented:
bhanukir7, your solution to shrink the VM was not the solution to the problem as described. In the original problem I already indicated that I knew to shrink the VM, the problem was that shrink required an equal amount of disk space. I was looking for a solution for what to do if a person does not have that available disk space. I cannot mark "shrinking the disk" as the solution because it would insult a person who found this thread looking for a solution to shrinking the disk without enough space. The appropriate solution is "There is no solution". It can't be done anyway, anyhow. If you have a VM that has grown larger than the available space on the disk, either find another disk or you will eventually run out of space and your VM will be unusable.
0
 
bhanukir7Commented:
Hi,

Instead of running the vmware tools from the VM to shrink the vmdk file use the command line tool

vmware-vdiskmanager.exe         this is available in the following location.

X:\Program Files\vmware\vmware workstation\

for us to get the shrink to work we should have exactly double the size of the VMDK.

but i think we dont have 300 GB disk rather it is only 250gb.

bhanu
0
 
aiscomAuthor Commented:
Yes, that is correct Bhanu I only have a 250GB disk so I do not have double the size of the vmdk. Any other way to reduce the size of the disk, maybe wioth VMWare converter, or Clone?
0
Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
bhanukir7Commented:
a clone would be a wonderful option but if this is a full clone i think it would simply do a copy of the vmdk file which would again lead to the same issue of 140 gb drive

vmware converter would be a better option i think
0
 
aiscomAuthor Commented:
Any ideas on how to use Converter to optimize? I tried running Converter on my current VM and selected remove restore points. No change in the size of the VM on the disk though.
0
 
bhanukir7Commented:
do you have any backup solution with agents to run backup of the VM a full backup of the VM installing a agent on it
0
 
aiscomAuthor Commented:
I do have a backup solution that can create a backup of the disk. You would suggest creating a backup, then a new VM and restore to that VM?

I am getting closer to a possible solution. I used the disk manager command line tool to "convert" the disk to a new Virtual Disk. I then edited the vmx config file and changed the filename of the disk to my new copy. The new copy is about the same size as the disk information.

The VM starts and runs but woudn't login to our office domain. I did not have a local login so I got stumped here. I loaded the original disk, updated the administrator password and am now making another copy (the same way as before) and hoping to get into the XP OS using the admin password instead of a domain login. I am wondering of the disk copy has "deactivated" my copy of Windows and that is why I cannot login to the domain.
0
 
bhanukir7Commented:
Hi,

When you do a disk copy it does not deactivate if you are using the same VMX file. But if you create another VM this changes the UUID of the VM which would cause the deactivation of license as the license is specific to hardware.

The best is to copy the UUID from the old image and then bring it online.

bhanu
0
 
aiscomAuthor Commented:
Turns out the reson I could copy the VM was because I was copying the parent disk of the VM which happens to be about the same size. When I tried with the current disk, the copy failed with not enough space.

I am too troubled with trying a backup and restore to new VM so I think I may just be headed off to find a 500GB drive.
0
 
aiscomAuthor Commented:
I have never found a resolution. I added a 500GB drive to the system and ran the shrink successfully. Let this be a lesson to anyone else running these virtual machines. NEVER let VM's take more than 50% of the drive.
0
 
bhanukir7Commented:
hi aiscom,

if the issue is put to rest then please close the question.

bhanu
0
 
bhanukir7Commented:
hi

what ultimately resolved the issue was one of the recommendations made. I.e. is to run the shrink on the vm which will reduce the disk space. As you had disk space constraints you had add additional space to be able to shrink the file which answered your question.

Can you please change your comments and close the question saying you could not resolve the issue with the available resources as after adding the additional disk you followed what has been provided as a solution.

I dont worry about the points, you certainly claim a refund of points but dont try to say the solution was not helpful.

0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.