Increasing a VMDK file size using VMKFS tools
This article provides the steps to extend a Vmware VMDK virtual disk file from command-line with the Vmware utility vmkfstools.
Steps to Follow:
- Power Off the VM Guest
- Undeploy the VM Guest if in Lab Manager
- Remove any snapshots
- Consolidate if a template in Lab Manager
- Login to the VM Host Console
- Change directories to the appropriate path to the VM Guest
- Example: cd /vmfs/volumes/<datastore>/<vm guest>
- Optionally create a backup of the VM disk
- Example: vmkfstools -i <vmname>.vmdk -d thin backup-<vmname>.vmdk
- Extend the disk size
- Do Not run the command on the file name with flat. Run it against the smaller meta file that just ends in vmdk.
- Example: vmkfstools -X 60G <vmname>.vmdk
- The new size will be 60 GB
- Deploy the VM Guest if in Lab Manager
- Power On the VM Guest
- Use a partition management utility if older than Windows Vista/2008 to extend the partition with the new unallocated space in the OS.
- Remove backup VMDK when satisfied that it was successful.
- Done
Reerence sources:
http://communities.vmware.com/docs/DOC-2459
Note: If you consolidate a VM guest in Lab Manager it will convert the VMDK files to thick. So at the end of this process you may want to follow the steps to convert it back to thin which will update soon.
No comments:
Post a Comment