VMware Arena

Resizing VMDK size using Vmkfstools

This post explains about the step by step procedure to expand the virtual machine VMDK size using vmkfstools. Prior ESX 3.5, There is no option to extend the virtual hard disk size from vSphere client. Virtual harddsik expansion can be done only via CLI with the help of vmkfstools command and also you need to power down the virtual machine before proceeding with the below steps prior ESX 3.5.

Log in to the ESX using SSH with the root credentials.

Before proceeding with the expansion step . Let’s take a look at my virtual machine “winxp-arena” has hard disk with the provisioned size of 14 GB

Browse towards the location of VMDK file of the particular virtual machine.In my case, /vmfs/volumes/datastore1/winxp-arena

Type ls -l to see the list of files located on the virtual machine folder and note down the vmdk name “winxp-arena.vmdk

I am going to expand my virtual machine vmdkwinxp-arena.vmdk”  from 14 GB to 20 GB i.e increasing 6 GB of additional hardisk space. Execute the below command

vmkfstools -X  20G /vmfs/volumes/datastore1/winxp-arena/winxp-arena.vmdk

Let’s check the VMDK file size by browsing the virtual machine directory and type ls -l. Note the size of VMDK size is expanded to 20 GB and disk size appearing above in bytes

Thanks for Reading !!!

Exit mobile version