Creating empty VMWare .vmdk files

This article has 19,539 views

Having empty vmdk files allows you to
– create virtual machines even with vmware player
– create additional disks and add them to existing vmware installations

The easiest way to create custom vmdk ‘disks’ is by using a free online tool called "EasyVMX"  (http://www.easyvmx.com)
Use EasyVMX version 2 to create a virtual machine : http://www.easyvmx.com/new-easyvmx.shtml
The end result is a set of vmdk and vmx files, zipped and made available on the easyvmx website for download. Luckily, because the files are more or less empty, the total zip file size is only a couple of Kb

Other vmware images can be found at http://www.clusterbuilder.com/vmware/vmware.html

Also, you can use Qemu to create vmdk files as well : http://fabrice.bellard.free.fr/qemu/

This is a command line utility, but you can find a GUI on http://www.davereyn.co.uk/qemu.htm

(use http://www.consolevision.com/members/dcgrendel/vmxform.html to create a vmx file, the tool on http://petruska.stardock.net/software/vmware will do this for you as well.

 
Another great and easy way to create vmdk files is by using VBA code (yes, even from within Excel !)
Open Excel, create a macro. Add a TLB reference to VMWare Virtual Image Editing 2(VIE2) 1.0 type library

Dim vl As New VIELIB2Lib.Vie2Locator

Sub test()
vl.CreateVirtualDisk "c:\vm\test.vmdk", 0, "IDE", 10
End Sub

  

Next, make a vmx file (use a tool, or just take an existing vmx file and modify it; or just create a new file yourself)

 ==================
config.version = "8"
virtualHW.version = "3"
ide0:0.present = "TRUE"
ide0:0.fileName = "test.vmdk"
ide0:0.mode = "persistent"
ide0:0.deviceType = "ata-hardDisk"

memsize = "64"
MemAllowAutoScaleDown = "FALSE"
####### floppies ######################
floppy0.present = "TRUE"
floppy0.startConnected = "TRUE"
floppy0.fileType = "file"
floppy0.fileName = "drivers.flp"

usb.present = "TRUE"
sound.present = "TRUE"
sound.virtualDev = "es1371"
displayName = "Windows XP Pro"
guestOS = "winxppro"
nvram = "test.nvram"
MemTrimRate = "-1"

tools.syncTime = "TRUE"
ide1:0.startConnected = "TRUE"

uuid.action = "create"

checkpoint.vmState = ""

ide0:0.redo = ""
uuid.location = "56 4d e2 39 18 fd 8e 17-98 7c c8 46 3b 1f f2 fe"
uuid.bios = "56 4d e2 39 18 fd 8e 17-98 7c c8 46 3b 1f f2 fe"
========

In the example above, you’ve noticed that the floppy is linked to a flp file. You can create custom flp files using rawrite for Windows http://www.chrysocome.net/rawwrite

   

Finally, the following link contains useful information regarding the process of creating vmx files : http://www.virtualization.info/2005/12/guide-to-create-vmx-files-for-vmware.html

© Corelan Consulting BV. All rights reserved. ​The contents of this page may not be reproduced, redistributed, or republished, in whole or in part, for commercial or non-commercial purposes without prior written permission. See the Terms of Use and Privacy Policy for details.