External Links

HowTo's‎ > ‎

VMware Server to Citrix XenServer

posted Jan 14, 2012 1:49 PM by Carlos Silva

I had a private server running VMware Server 2.0.2 but the lack of updates to this product made me try to switch to another platform. First thing I tried was to get VMware ESXi running on the same server. The problem with this is that ESXi has very limit support to "White Boxes", as in, personal computers. So I couldn't get to install ESXi.

So I searched for alternatives. One thing that was always comming up was Citrix XenServer, so I decided to give it a try. All I can say is, this thing *rocks* !!!! :D

I just had one little problem with my network card (Realtek 8168 PCIExpress), but it was easily solved by adding this to /etc/modprobe.conf:

options r8169 use_dac=1

With this simple line, I had my network working and the Citrix XenServer was operational! Now let's migrate my old VM to this new box. The old VM was a Windows XP x86.

Googleing a bit, led me to find XenConvert, an utility made by Citrix to convert several types of VMs to XenServer. It had support to VMDK (VMware Disk format) so I dicided to use it.

It was a complete fail. All my tries to import the disk to XenServer worked but the disk was never readable and the VM wouldn't boot no matter what.

The solution I found was to convert the VMDK file to a VHD file (Virtual Hard Disk used by Microsoft Virtualization server) using XenConvert, move this file to the server, and import it directly on the server. But now you say: "But XenServer can't import a VHD file". That's where the news is :)

Looks like Acronis has a free tool that makes this happen and it's called vhd2xen. The link is here.

I downloaded vhd2xen and installed it on the server. Next I just imported the vhd using this simple command:

/usr/lib/Acronis/VHD2XEN/vhd2xen.sh <path_to_vhd_file>

All it was asked was what Local Storage on the XenServer I wanted the disk in and the Disk magically appeared in there :)

All was needed was to create a new VM in XenCenter and assign the imported disk to it and BUM, it boots and the disk is fine! :)

 

Hope this can help somebody in the same situation as I was.