VMware Communities
patcc2
Contributor
Contributor
Jump to solution

VMDK File Size Waste

I am desperately trying to reclaim system space and it seems like VMware wants to fight every inch to make that not happen. 

Problem:

I have a 500GB Windows host machine with a 250GB Linux VM. Currently the host has 35GB free. Inside the VM Linux is reporting a usage of 195GB which is about what I expect. If I check the VM settings I see "Current size 97.8 GB". However, I previously had 2 snapshots so the vmdk is labeled Mint-000002.vmdk. When I check the size of the vmdk files on my host machine they total 296GB which implies to me that almost 100GB is just made up waste. I desperately need this storage back I have tools generating piles of data but nothing can run because my drive keeps filling and then not being freed back to the host. 

What I have tried:

  • Deleted the snapshots. "An error occurred while consolidating disks: There is not enough space on the file system for the selected operation." - no change in space.
  • Delete some of the vmdk files - Causes failure to load all of the snapshot vmdks seem to have this parentFile parameter so all of the vmdks need to exist.
  • Run both Defragment and Compact from the Virtual machine settings menu - Says that it completes after some time. Reclaimed maybe 10GB I was previously at 330GB used so it went down somewhat but no where near where it reasonably should be.
  • vmware-vdiskmanager -k Mint.vmdk (and the snapshot ones) - Again slightly reduced the size by maybe 10GB but still have this massive waste of over 100GB.

Please any suggestion to solve this would be greatly appreciated. Also if someone can explain how this happened I would love to understand. Did my previous snapshots cause me to have massive duplicates of data which now I lack the drive space to clear up?

Reply
0 Kudos
1 Solution

Accepted Solutions
RDPetruska
Leadership
Leadership
Jump to solution


@patcc2 wrote:

I am desperately trying to reclaim system space and it seems like VMware wants to fight every inch to make that not happen. 

Please any suggestion to solve this would be greatly appreciated. Also if someone can explain how this happened I would love to understand. Did my previous snapshots cause me to have massive duplicates of data which now I lack the drive space to clear up?


Basically, yes.   A snapshot freezes the current virtual disk files and creates a new starting copy, which depends upon the parent disk files to remain.  In order to remove a snapshot and merge the files, you MUST have enough disk space for the disk files to be copied before they can be deleted.

You will need to either free up disk space on your host, or move the ENTIRE VM's folder to another computer/drive with enough free space to merge the snapshot files.

View solution in original post

Reply
0 Kudos
5 Replies
RDPetruska
Leadership
Leadership
Jump to solution


@patcc2 wrote:

I am desperately trying to reclaim system space and it seems like VMware wants to fight every inch to make that not happen. 

Please any suggestion to solve this would be greatly appreciated. Also if someone can explain how this happened I would love to understand. Did my previous snapshots cause me to have massive duplicates of data which now I lack the drive space to clear up?


Basically, yes.   A snapshot freezes the current virtual disk files and creates a new starting copy, which depends upon the parent disk files to remain.  In order to remove a snapshot and merge the files, you MUST have enough disk space for the disk files to be copied before they can be deleted.

You will need to either free up disk space on your host, or move the ENTIRE VM's folder to another computer/drive with enough free space to merge the snapshot files.

Reply
0 Kudos
patcc2
Contributor
Contributor
Jump to solution

Except my VM is taking up 300GB on a 500GB host machine. It would be impossible for me to ever reclaim enough space I feel like, factoring in for the OS and such. 

 

That said I can not find the consolidate button, where is it in VMware Workstation? Do I just create a 3rd snapshot and delete it immediately to try and force consolidation and see if I have enough free storage? 

 

Also more a question of design, why is VMware not checking for this on startup. It knows I have snapshots and it knows roughly how much space I would need to delete the snapshot. If it sees me walking into this death spiral I feel like a little warning would have been really nice. 

Reply
0 Kudos
RDPetruska
Leadership
Leadership
Jump to solution

The creation/editing of snapshots is a feature of Workstation Pro.  Player can only run a VM which has snapshots.

Workstation knows you have snapshots, sure... but not what you might want to do with them.

As I said, either move to an external disk or a different PC altogether to be able to perform the disk utility tasks.

Reply
0 Kudos
Technogeezer
Immortal
Immortal
Jump to solution

Also, how is that virtual disk configured? Is it configured to be "sliced" or a single file? Those decisions impact how host disk space can be consumed or released.

- Paul (Technogeezer)
Editor of the Unofficial Fusion Companion Guides
Reply
0 Kudos
patcc2
Contributor
Contributor
Jump to solution

It is sliced. I'm currently copying everything to a network drive to hopefully clean things from there. Should I create a snapshot then hit delete all to try and force consolidation of the old snapshots or is there another way? 

Reply
0 Kudos