Recently, I built a new machine for my lab (for those interested in the story, here are Parts I, II and III). I put a 512GB SSD in the new machine with the aim to thin-provision all virtual machines but still get good performance, due to the high number of IOPS/read/write you get from SSDs. Once built, I wanted to transfer some of my pre-existing thick-disk virtual machines from another machine (placed on a traditional RAID 10 array) to the new one. Obviously, I also wanted to convert the disk format to thin in the process.
There are a few ways of doing it in vSphere, either from vCenter or command-line. However, when it comes to VMware Workstation, there isn’t an option in the GUI. A quick search reveals that people tend to suggest VMware Converter as the tool to do it. In this quick post, I just wanted to remind people of another built-in but often forgotten command-line utility, bundled with VMware Workstation for years: VMware Virtual Disk Manager.
Not only the utility has existed for a good few years now, it hasn’t changed much and can carry out all sorts of disk-related tasks, including creation, deletion, expansion, de-fragmentation, consistency checks, repair and importantly for me, conversion into the various formats e.g. thin. It even converts the disk for transfer to ESX.
So, I used this utility to convert my thick-disk based virtual machines to thin. It’s pretty fast and skips the white spaces so doesn’t take very long (depending on disk size). Here is the command that I used:
vmware-vdiskmanager -r “Source Disk.vmdk” -t 0 “Target Disk.vmdk”
As I didn’t want to split the disks, I chose the “-t 0” option, however, other options are also available. In my case, the machines went from VMware Workstation 8.0 to 9.0 but that didn’t make any difference as version 8.0 machines are also supported in 9.0. I also converted some of the machines to version 9.0 later without any issues. All machines have been working fine after conversion.
If you haven’t already, have a look at this utility. I am sure you’ll find that there isn’t any disk-related task that you can’t do with it.
Hope it helps!
Leave A Comment