Skip to end of metadata
Go to start of metadata

A simple step-by-step migration guide from a ESXi VMware to a SmartOS KVM branded vm.

Disclaimer: the steps are developed based on advice from Orlando Vazquez on the mailing list and refined with some trial and error.

Getting stuff out of ESXi

This might be the most tricky part since the obvious choice, vCenter Converter is a surprisingly bad one. Instead the trick is to use a semi-secret tool: ovftool. It is a command line tool, sadly it does not work directly on SmartOS, for my tests I ran it on my laptop and it worked fine. The syntax is about the following:

Now this will take a while, so sit back and relax, upside is it will only copy the data really used be the VM. Once the program is through you will get somethig like:

And now for something completely different

Now comes the fun part, create the new VM. Look at How to create a Virtual Machine in SmartOS for details. Only addition here: you need to create a disk with the correct size for each .vmdk you want to import. You can double-check the size of the virtual disk with qemu-img:

Once you run vmadm create, you will see something like this if you do zfs list (e0950735-dae5-481d-911a-80b14844759a would be the UUID of your VM)

So what we must do now is put our vmdk file into the zfs zvol, fortunately qemu-img comes to our help here, it allows writing our vmdk directly to the disk we created. (thanks to nahamu for suggesting that).

This does not work on all types of vmdk images!

You can boot your VM now and should see your migrated data as if it were never somewhere else.

Final words

If you have more then one disk just repeat the steps for each disk. Also be aware that the image will use the full size and not sparse.

Labels:
None
Enter labels to add to this page:
Please wait 
Looking for a label? Just start typing.