Clone VM on ESXi 4.1

  1. If you hadn't activate SSH then do this as described here.
  2. Create a new VM with the same configuration as the machine you wish to clone.
  3. By creating the VM you also created its virtual disk (*.vmdk).
  4. Delete this disk (we will replace it with the clone) by using the “Datastore Browser” or SSH on ESXi.
  5. Connect to your ESXi by using SSH.
  6. type the following command (here “ubu-10.04-server” is the template).
vmkfstools -i /vmfs/volumes/datastore1/ubu-10.04-server/ubu-10.04-server.vmdk /vmfs/volumes/datastore1/newmachine/newmachine.vmdk
Destination disk format: VMFS zeroedthick
Cloning disk '/vmfs/volumes/datastore1/ubu-10.04-server/ubu-10.04-server.vmdk'...
Clone: 100% done.