Cross pool migration with XO

Hi everyone! A blog post about a new cool feature freshly implemented in Xen Orchestra: cross pool migration, AKA migration without shared storage (or Storage Xen Motion).

Concepts

In XenServer, you have to type of live migration: Xen Motion and Storage Xen Motion.

Xen Motion

Easy one. That's the name of migrating hosts with hosts sharing the same storage (NFS or iSCSI+LVM). It's already working in Xen Orchestra since... a long time!

In this case, the content of the RAM is sent over the network by Xen, from one host to another. Thus, RAM size and the network speed are correlated to the migration time.

Storage Xen Motion

The one I like the most. This time, a storage is not shared between hosts. In order to migrate a VM, you need to achieve multiples steps:

  1. move the whole VM storage, network and configuration to another host
  2. when it's done, migrate what's left: the RAM
  3. finally, the "old" VM is removed on the original host

This process can be quite long: if your VM have a 100Gig disks, well... You need to transfer all of it!

But you stay safe: your VM is always online during the transfer!

In Xen Orchestra

xo-server

We just implemented this feature in the next-release branch of xo-server. It's already available in xo-cli, see for yourself:

xo-cli vm.migrate_pool id=VM_UUID target_host_id=HOST_UUID target_sr_id=SR_UUID target_network_id=NET_UUID migration_network_id=NET_UUID

I have to say, xo-cli is a very useful tool to test quickly our new features in xo-server!

Unlike xe, you don't have to write the IP or the host password, because you are already connected. We just tested it, and it works :)

Simplify

But hey, if I don't want to use all those parameters, just to give the VM and the host target? Well, you can do it! Because XO will automatically pick default options:

  • the default SR on your host/pool will be chosen by XO, as a targeted SR
  • the targeted network chosen by default will be the one used by the management interface.
  • idem for the migration network

Thus, the previous command will be shorter:

xo-cli vm.migrate_pool id=VM_UUID target_host_id=HOST_UUID

That's it!

Migration in the UI (xo-web)

We choose to use Xen Storage Motion without getting another button. For doing this, the VM will be migrated normally first. If it fails (no shared storage), this window will be displayed:

By clicking on "OK", the VM will be moved to the targeted host!

This feature was already tested and the code is in the next-release branch. Stay in touch for a new release with this feature in XOA!