Clone VMware with a command line


Here is a simple way to clone or copy a machine, you can do that by copying the Virtual Hard disk drive (*.vmdk) file.

by using the command  vmkfstools -i “SOURCEDISKIMAGE.vmdk” “TARGETDISKIMAGE.vmdk”

another example: vmkfstools –i /pathtoTemplateVM/template.vmdk /pathtoDestinationVM/newvm.vmdk

Advertisements
This entry was posted in VMware and tagged , , . Bookmark the permalink.

2 Responses to Clone VMware with a command line

  1. Why do you need to do that?

    You can also go to the VI client, connect to the esx server, browse the datastore (double click on the data store), create a new directory, then just right-click-copy and paste the vmdk file to the new directory.

  2. lex says:

    @VaibhaV Sharma,

    because it involves less steps, its shorter, and scriptable.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

w

Connecting to %s