VMware Communities
renatob
Enthusiast
Enthusiast
Jump to solution

Can I delete vmdk files

I've a situation here: more than 40 gb in vmdk files.

So, I would like to know is possible to delete these files and how can I do this.

Thanks in advance for any help

Captura de Tela 2015-10-05 às 10.32.30.png

Tags (2)
1 Solution

Accepted Solutions
VIR2AL3X
Enthusiast
Enthusiast
Jump to solution

renatob‌, please read my previous comment.  You should not delete these files as you will break your virtual machine.  The reason you have so many vmdk files is because they are being split up into 2GB files.  Following the directions I outlined in the previous post will convert all of these split files into a single VMDK disk file.  Then I'd recommend performing a disk cleanup to compress the VMDK and reclaim some space.

Yo do this by going to the settings of the VM, clicking General, then Clean Up Virtual Machine.  Hope this helps!

2015-10-05_15-01-46.png2015-10-05_15-01-57.png

View solution in original post

0 Kudos
8 Replies
schepp
Leadership
Leadership
Jump to solution

Hi,

I guess you have your VM configured to split your hard disk into 2GB files.

Take a look at Virtual Machine - Settings - Hard Disk

There should be a "split into 2GB files" checkmark set.

So deleting any of those vmdk files will break your VM and make it unusable.

Tim

greco827
Expert
Expert
Jump to solution

These are .vmdk files associated with an active VM/VM's?  If so, it will absolutely impact your VM's stability, if not crash it altogether.  They should be locked if the VM is running.

If you are unsure if they are "orphaned", try running this PowerCLI script:

Virtually Jason: Orphaned VMDK Files

If you find this or any other answer useful please mark the answer as correct or helpful https://communities.vmware.com/people/greco827/blog
0 Kudos
wila
Immortal
Immortal
Jump to solution

Hi,

That script won't work as it is for vSphere, not for VMware Fusion.

The start post is about a virtual machine in VMware Fusion, powerCLI doesn't work on OS X Smiley Happy

--

Wil

| Author of Vimalin. The virtual machine Backup app for VMware Fusion, VMware Workstation and Player |
| More info at vimalin.com | Twitter @wilva
0 Kudos
Mikero
Community Manager
Community Manager
Jump to solution

Yah, don't delete .vmdk's unless you know it's safe to do so.

Those are not safe to delete. You WILL break your VM.

Think of .vmdk's as a representation of your C:\ drive.

When you add them all together, you get the virtual disk that Windows can use as C:\.

So, they're a critical component in how virtual machines work.

If you're having another issue, please describe for us so we can help.

If you're just looking to free up space, you'll have to find another way.

(of which there are several depending on your situation...)

-
Michael Roy - Product Marketing Engineer: VCF
VIR2AL3X
Enthusiast
Enthusiast
Jump to solution

renatob What you should do instead is go into the settings of the VM, select the Hard Disk, then Advanced options drop down and uncheck the box for "Split into multiple files".  This will then convert the split files into a single VMDK file.  It will take some time to convert to just let it run.  Hope this helps!

2015-10-05_14-31-53.png

renatob
Enthusiast
Enthusiast
Jump to solution

Thanks Tim

But I need to know too if I can delete these files and how do I remove.

0 Kudos
VIR2AL3X
Enthusiast
Enthusiast
Jump to solution

renatob‌, please read my previous comment.  You should not delete these files as you will break your virtual machine.  The reason you have so many vmdk files is because they are being split up into 2GB files.  Following the directions I outlined in the previous post will convert all of these split files into a single VMDK disk file.  Then I'd recommend performing a disk cleanup to compress the VMDK and reclaim some space.

Yo do this by going to the settings of the VM, clicking General, then Clean Up Virtual Machine.  Hope this helps!

2015-10-05_15-01-46.png2015-10-05_15-01-57.png

0 Kudos
wila
Immortal
Immortal
Jump to solution

Using a single disk for your VMDK files over a split disk as you have already is a big disadvantage.

Once your vmdk is a single disk, for any action like shrink or commit a snapshot you now need the full disk size on your host to be free.

IOW, you need a LOT more free disk space on your host.


Say you have a 40GB virtual disk made up of 20 times 2GB slices. You only need to have 2GB (plus a bit) of free disk space to clean up your disk.

If the disk is 40GB single slice, you may need up to 40GB (plus a bit) free on your host for that same action.

How much is needed for the single slice depends on the actual size that has been allocated.

--

Wil

| Author of Vimalin. The virtual machine Backup app for VMware Fusion, VMware Workstation and Player |
| More info at vimalin.com | Twitter @wilva