Howto – Convert a VMDK from Thick to Thin provisioning on ESXi Server


This article gives the steps to convert a thick provisioned virtual hard drive VMDK to thin provisioned on ESX 4 or newer.

Option 1

  1. Migrate the VM Guest to another datastore and change the advanced configuration of the hard drive to thin provisioned.

Option 2

If you can’t vMotion of migrate the VM to another datastore you can use the this the vmkfstool command from the VM host to convert it.

  1. Optional
    1. Login to the VM Guest
    2. Make sure the VMTools are updated
    3. Run an OS Defrag of the drives
    4. Use Microsoft SDelete
      2. Download and install on the VM Guest OS
      3. Run sdelete -c
  2. Power Off the VM Guest
  3. Login to the VM Host that has the VM Guest either by Power CLI or SSH
    1. You may need to enable SSH and ESX Shell to do this
  4. Browse to the VM Guest file location
    1. Example: cd /vmfs/volumes/mydatastore/vmname/
  5. Clone original disk to a thin copy
    1. vmkfstools -i SERVERNAME.vmdk -d thin thin-SERVERNAME.vmdk
  6. Rename the original disk
    1. vmkfstools -E SERVERNAME.vmdk orig-SERVERNAME.vmdk
  7. Rename the thin disk to the original disk name
    1. vmkfstools -E thin-SERVERNAME.vmdk SERVERNAME.vmdk
  8. Remove VM Guest from VM Host inventory
  9. Add the VM Guest back to the VM Host inventory
    1. This so the VM Host registers that it’s now a thin provisioned disk/s
    2. This may not be needed for vSphere 5
  10. Verify that the VM Guest boots and runs correctly
  11. Remove original Thick disk/s
    1. ​vmkfstools -U orig-SERVERNAME.vmdk​

Published by

Ronny Van den Broeck

I'm a network and system engineer for more than 20 years now. During this period I became a pro in hunting down one's and zero's, with an eager mindset to help people accomplish the same or abstract them away from the matrix.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s