VMware Cloud Community
Katphish
Contributor
Contributor
Jump to solution

stubborn Thin provisioned disk

I am getting seriously curious what could be wrong with what I do.

I am stuck with a large thin provisioned disk.
it is on ESXI 7.0.0 (Build 15843807) not connected to any vCenter Server (yes, home lab 😄 )
It is a fresh Win7 VM i just created with a thin provisioned disk, as I was installing some soft it used up some temp size but now the drive is empty.

I tried SDDelete on the Win7 and then vmkfstools -K <disk name> no change, it is the size of the inflated disk. 
No size change when i do >ls -l

I tried to convert it, to thicken (inflate) it and then convert it back to thin 
>vmkfstools -j <path to RAID datastore><original.vmdk> (also tried "-d zeroedthick")
>vmkfstools -i <path to RAID datastore><original.vmdk> <path to SSD datastore><thin.vmdk> -d thin 
No size change when i do >ls -l

it is a <name>-flat.vmdk big file and <name>.vmdk small file

 

I am out of ideas.

 

 

0 Kudos
1 Solution

Accepted Solutions
Katphish
Contributor
Contributor
Jump to solution

To solve this I used VM VCenter Converter Standalone Client where converted the VM to use a thin drive.

It shrunk the VM from ~70GB to ~15GB. Then I moved the Drive back to ESXi and there the used space was close to 15GB, all seemed well.

For the test I applied defrag, then "DSDrive -z c:" in the guest (the drive grew back to ~70GB) and again vmkfstools -K <disk name> in ESXi to see if the thin will be shrunk as expected. Again was not.

The conclusion for me is that on my installation of ESXi vmkfstools -K <disk name> does not do the job it is supposed to.

"your mileage may vary"

 

View solution in original post

0 Kudos
7 Replies
a_p_
Leadership
Leadership
Jump to solution

Note hat an ls -l command will only show the provisioned size. If you also want to see the used disk space run e.g. ls -lisa, which will show the used disk space in KB in the second column.

André

0 Kudos
Katphish
Contributor
Contributor
Jump to solution

Thanks for the tip! I feel a step closer to solving this.
I noticed NTFS Compression was enabled for C: in the guest.
I had already disabled compressing the temp file which bugged SDDelete, now is completely off and after another process as below I get change in "ls -lisa". See the image below.
However the file is still large, Any Ideas how to shrink it?

 

2022-03-17 15_07_24-_new 1 - Notepad++.png

 

0 Kudos
Katphish
Contributor
Contributor
Jump to solution

Oh, and I am sure the file actually is ~70GB, i downloaded it 8-D

 

0 Kudos
a_p_
Leadership
Leadership
Jump to solution

Thin provisioning is a VMFS file system feature. Manually downloading the files to e.g. your PC will inflate the file, because the target file system does not support this feature.

It's not like the sparse files for VMware Workstation, or Fusion, where the .vmdk files contain metadata for allocated blocks within the files.

André

0 Kudos
Katphish
Contributor
Contributor
Jump to solution

Thanks for that! Did not know that as well 🙂

However, if i need to place 5 of them on my not so large SSD datastore they would take 70GB x 5 (did not fit, tested) and in the drive in guest the used capacity is reported as 20GB. It is a vast difference hence my question.

 

So, how to reduce the used up space?

 

 

0 Kudos
a_p_
Leadership
Leadership
Jump to solution

I'm not sure that I can follow you.
The previous screenshot shows that the used disk space is about 20GB, but now you are saying it's 70GB!?

Please clarify, and explain how exactly you are trying to move/copy the VMs to the SSD datastore.

André

0 Kudos
Katphish
Contributor
Contributor
Jump to solution

To solve this I used VM VCenter Converter Standalone Client where converted the VM to use a thin drive.

It shrunk the VM from ~70GB to ~15GB. Then I moved the Drive back to ESXi and there the used space was close to 15GB, all seemed well.

For the test I applied defrag, then "DSDrive -z c:" in the guest (the drive grew back to ~70GB) and again vmkfstools -K <disk name> in ESXi to see if the thin will be shrunk as expected. Again was not.

The conclusion for me is that on my installation of ESXi vmkfstools -K <disk name> does not do the job it is supposed to.

"your mileage may vary"

 

0 Kudos