VMware Cloud Community
HafedhGuiga
Contributor
Contributor
Jump to solution

Convert VM disk larger than 2 TB to Thin

Hello everyone,

I have a virtual machine with 2 different diks (ESXi 6.0):    

     -Disk 1 = 300 GB,

     -Disk 2 = 2.4 TB,

When i click on change Datastore and try to convert these disk to thin, everything seems OK, but when i refresh th disk properties, i still have the same size (Thick)!

Can you help me please.

Best regards,

Hafedh

1 Solution

Accepted Solutions
ThompsG
Virtuoso
Virtuoso
Jump to solution

Hi Hafedh,

Sorry to be asking this but are you expecting that within Windows the disks will look different after being converted to Thin? If so then let me reassure you that you will not see any difference either from Explorer or Disk Management. Both will still display the Provisioned size of the virtual disk.

To confirm if the virtual disk has been converted from Thick to Thin then open the settings for the VM and look at the settings for a Hard Disk. It should state the Type as Thin Provision if the conversion was successful.

Does this make sense?

Kind regards.

View solution in original post

7 Replies
Baoyin
VMware Employee
VMware Employee
Jump to solution

Could you please post a screen shot before you covert and after?

I guess the convert is done during migration, right?

can you run below commands with the vmdk after you coverted?

stat -c %b "Your vmdk abs path"

stat -c %B "Your vmdk abs path"

and post the result here?

Reply
0 Kudos
HafedhGuiga
Contributor
Contributor
Jump to solution

VM Convert.png

Hello and thank you for your response,

For the disk that exceeded 2 TB,it's GPT disk, i think that's the problem.

For the command, can you tell me where i have to run these commands ?

Thanks

Hafedh

Reply
0 Kudos
Baoyin
VMware Employee
VMware Employee
Jump to solution

Inside the ESXi to run the command

Reply
0 Kudos
HafedhGuiga
Contributor
Contributor
Jump to solution

this is the result of the two commands, Smiley Happy

Image 2.png

Thanks

Hafedh

Reply
0 Kudos
ThompsG
Virtuoso
Virtuoso
Jump to solution

Hi Hafedh,

Sorry to be asking this but are you expecting that within Windows the disks will look different after being converted to Thin? If so then let me reassure you that you will not see any difference either from Explorer or Disk Management. Both will still display the Provisioned size of the virtual disk.

To confirm if the virtual disk has been converted from Thick to Thin then open the settings for the VM and look at the settings for a Hard Disk. It should state the Type as Thin Provision if the conversion was successful.

Does this make sense?

Kind regards.

HafedhGuiga
Contributor
Contributor
Jump to solution

Hello and thank you for your response,

The problem, is that i have converted many other virtual machines and when i change the type of the disk from thick to thin, i can see that the storage used in VM Settings is the storage used inside the Virtual machine.

But you are right about the provisionned storage. Because for this virtual machine in particular, the provisionned storage is 1 TO (Allocated is 2.3 TO) so it's logic to see 1 TO used even if really i used 100 GO of Storage.

Thanks again for your response

Have a nice day

Hafedh

Reply
0 Kudos
ThompsG
Virtuoso
Virtuoso
Jump to solution

Hi Hafedh,

Glad I was able to help. If you want to "shrink" the Thin disks to what the OS is using then you may need to do a couple of additional steps to make this happen:

  1. Download a utility called SDelete (from SysInternals) and run it with -z option, i.e. sdelete -z c:
  2. Defrag the drives with defrag /C /H /V /X

These steps will zero and consolidate the files within your VM and therefore the blocks should be released when you convert the disks to Thin.

This should leave you with virtual disks that are only consuming the actual blocks used within the guest OS.

Kind regards.

Reply
0 Kudos