VMDK virtual disk type

Version 8

    VMware virtual disk type

    There are different type of virtual disks in VMware world.

     

    From point of view related with the disk size there are two different types:

     

    • thick (or preallocated)
    • thin (or dynamically)


    From point of view related with the number of files there are two different types:

     

    • monolithic (a single data file)
    • split (more data files, usually with a fixed size like, for example, 2 GB)


    In ESX Server only monolithic format (thin or split) is directly supported.
    In VMware Server and Workstation also split format is supported.

     

    For more information see:
    http://www.vmware.com/files/pdf/thin_provisioning_datasheet.pdf
    http://thinkvirtualization.net/2009/02/the-thick-and-the-thin-of-a-vmdk/

     

     

     

     

    Choose the right type

    Choosing a virtual disk type for VMware Workstation/Server:
    http://sanbarrow.com/vmdk/monlithicversussplit.html

     

    Choosing a virtual disk type for VMware ESX:
    http://searchvmware.techtarget.com/tip/0,289483,sid179_gci1348873,00.html

     

    Disk type performance:
    http://www.vmware.com/pdf/vsp_4_thinprov_perf.pdf

     

     

     

     

    Disk type in ESX

    ThickZeroedThickThinEagerZeroed Thick
    Creation TimeFastSame as ThickFastestExtremely slow, and linearly proportional to size of disk
    Block AllocationFully preallocatedSame as Thick
    • Allocated, on demand, on first write to the block
    • Zero size on creation
    Same as Thick
    Virtual Disk LayoutDue to preallocation, it has a higher chance of using contiguous file blocks.Same as ThickLayout varies according to dynamic state of the volume at the time of on-demand block allocation.Same as Thick
    Zeroing of Allocated File BlocksFile blocks are not zeroed out.File blocks are zeroed, on demand, upon first write to virtual disk.File blocks are zeroed out upon block allocation.File blocks are zeroed out upon creation of the virtual disk (blocks are allocated and zeroed).
    I/O speedMax all the timeReduced at beginning due to zeroing blocks on first accessReduced slightly more than ZeroedThick due to allocating and zeroing blocks on first accessSame as Thick
    SecurityInsecure - VM can read what was on partition before VM deploymentSecureSecureSecure

     

     

    Source: http://communities.vmware.com/message/1380846

     

     

     

     

    Type conversion

    With Workstation there is the vmware-vdiskmanager command:
    http://kb.vmware.com/kb/1004022

     

    With ESX there is the vmkfstools command:
    http://vmetc.com/wp-content/uploads/2007/11/man-vmkfstools.txt

     

    With ESX and vCenter Server is possible use the "migrate" function to  move vmdk files and (if needed) change the type (between thin and  thick). But all disks will have the same format.
    With SVMotion license this operation could also be done the a "live" VM.
    Without vCenter Server, is possible convert a thin disk to a thick with  datatostore browser and the inflate option on the vmdk file (but the VM  must be powered off).
    To convert a thick disk to a EagerZeroed (for FT usage), simple enable  FT on a powered-off VM: the disk will be automatically converted!

     

    Note that by default ESX/ESXi disks are ZeroedThick, from vSphere is  possible (also from the GUI) build thin disks (choosing "thin  provisioning") or EagerZeroed Thick disks (choosing "support clustering  feature").

     

    Type conversion in ESX/ESXi 4

     

     To ThinTo (Zeroed) ThickTo EagerZeroed Thick
    From other vmdk formatvmkfstools*
    Standalone Converter 4*
    vmkfstools*
    Converter 3, 4*
    vmkfstools*
    Standalone Converter 4*
    From Thinvmkfstools*
    Datastore browser / inflate (on vmdk)*
    Converter 3, 4*
    SVMotion**
    vmkfstools*
    Standalone Converter 4*
    From (Zeroed) Thickvmkfstools*
    Standalone Converter 4*
    SVMotion**
    vmkfstools*
    Enable FT on the VM*
    Standalone Converter 4*
    EagerZeroed Thickvmkfstools*
    Standalone Converter 4*
    SVMotion**
    vmkfstools*
    Converter 3, 4*
    SVMotion**

     

     

    * Cold conversion
    ** Live conversion