XenCenter

Migrate Virtual Machines

This topic contains information about migrating and moving virtual machines within and across pools and standalone servers.

Definitions:

  • Migrate a VM: Move a running or a suspended VM to a different server or a pool.
  • Move a VM: Move a shut-down VM to a different server or pool.

Live migration

Live migration is available in all versions of XenServer. This feature allows you to move a running or a suspended VM between XenServer servers, when the VM’s disks are on storage shared by both servers. This capability allows for pool maintenance features such as Workload Balancing (WLB), high availability, and Rolling Pool Upgrade (RPU) to automatically move VMs. Storage can only be shared between hosts in the same pool. As a result, you can move VMs only within the same pool.

During the live migration of a VM, its memory is transferred as a data stream between two hosts using the network. The migration stream compression feature compresses this data stream, speeding up the memory transfer on slow networks. This feature is disabled by default, but this can be changed by using XenCenter or the xe CLI. For more information, see Pool Properties - Advanced and Pool parameters.

Live migration enables the following to occur without any VM downtime:

  • Workload leveling
  • Infrastructure resilience
  • Upgrade of the server software

Storage live migration

Storage live migration allows a VM to be moved from one host to another when the VMs’s disks are not on storage shared between the two hosts. As a result, you can migrate VMs stored on local storage without downtime and you can move VMs from one pool to another with virtually no service interruption. The choice of destination server depends on how the VM and the pool are configured. In a pool with Workload Balancing (WLB) enabled, for example, recommendations are provided to help select the best possible physical server for the VM’s workload. For more information, see Choosing an Optimal Server for VM Initial Placement, Migrate, and Resume.

Storage live migration enables system administrators to:

  • Rebalance VMs between XenServer pools (for example from a development environment to a production environment)
  • Upgrade and update standalone XenServer servers without any VM downtime
  • Upgrade the XenServer server hardware

Note:

  • Migrating a VM from one host to another preserves the VM state. The state information includes information that defines and identifies the VM and the historical performance metrics, such as CPU and network usage.

  • To improve security, you can close TCP port 80 on the management interface of your XenServer hosts. However, you cannot migrate a VM from a Citrix Hypervisor 8.2 CU1 pool without hotfix XS82ECU1033 installed, to a XenServer pool with port 80 closed. To do so, install XS82ECU1033 on your Citrix Hypervisor 8.2 CU1 pool or temporarily open port 80 on your XenServer pool. For more information about how to close port 80, see Restrict use of port 80.

Storage live migration also allows you to move virtual disks from one Storage Repository (SR) to a different SR within the same pool. For more information, see Move Virtual Disks.

Compatibility requirements

When migrating a VM with live migration or storage live migration, the new VM and server must meet the following compatibility requirements.

General requirements:

  • The target host must have the same or a more recent version of XenServer installed as the source host.

  • XenServer VM Tools for Windows must be installed on each Windows VM that you want to migrate.

  • You cannot concurrently migrate more than three VMs that have their source location in the same pool.

CPU requirements:

  • If the CPUs on the source and target host are different, the target host must be at least as capable as the source host. Generally, this means that the target has the same or a newer CPU.

    • If you are migrating within the same pool, the pool automatically attempts to make a VM compatible.
    • If you are migrating between pools, you must ensure that the VM is compatible with the feature set in the destination pool.
  • You cannot live migrate a VM between AMD and Intel processors.

Memory requirements:

  • The target host must have sufficient spare memory capacity or be able to free sufficient capacity using Dynamic Memory Control. If there is not enough memory, the migration fails to complete.

  • Storage migration only: A host in the source pool must have sufficient spare memory capacity to run a halted VM that is being migrated. This requirement enables the halted VM to be started at any point during the migration process.

Disk space requirements:

  • Storage live migration only: The target storage must have enough free disk space available for the incoming VMs. The free space required can be three times the VDI size (without snapshots). If there is not enough space, the migration fails to complete.

  • The source storage must have enough free disk space to create temporary snapshots of the VM’s VDIs during the migration. If there is not enough space, the migration fails to complete. The free space required can be up to two times the size of the VM’s disk.

Live migration and storage live migration limitations

Live migration and storage live migration are subject to the following limitations:

  • Storage live migration cannot be used with VMs created by Machine Creation Services.
  • VMs using SR-IOV cannot be migrated. For more information, see Use SR-IOV enabled NICs
  • VM performance is reduced during migration.
  • If using the high availability feature, ensure the VM being migrated is not marked as protected.
  • Time to completion of VM migration depends on the memory footprint of the VM, and its activity. In addition, the size of the VDI and the storage activity of the VDI can affect VMs being migrated with storage live migration.
  • VMs that have the on-boot option set to reset cannot be migrated. For more information, see Intellicache.
  • You cannot use storage live migration to migrate VMs that have changed block tracking enabled. Disable changed block tracking before attempting storage live migration. For more information, see Changed Block Tracking.

For step-by-step instructions on using live migration or storage live migration to migrate your VMs, see the section To Migrate or Move a VM.

Move VMs

XenCenter allows you to move shut-down VMs to a new storage repository in the same pool by using the Move VM wizard. For step-by-step instructions, see the following section.

To migrate or move a VM

  1. In the Resources pane, select the VM and do one of the following depending on the status of your VM.
    • To migrate a running or suspended VM using live migration or storage live migration: On the VM menu, select Migrate to Server and then Migrate VM wizard. This action opens the Migrate VM wizard.

      Note:

      For pools with 16 or fewer members, the right-click menu displays the list of available servers to migrate the VM to. However, for larger pools, the servers are not listed in the menu. Instead you must open the Migrate to Server wizard.

    • To move a stopped VM: On the VM menu, select Move VM. This action opens the Move VM wizard.

  2. Select a standalone server or a pool from the Destination list.
  3. Select a server from the Home Server list to assign a home server for the VM and select Next.
  4. On the Storage page, specify a storage repository to place the virtual disks of the migrated VM on. Select Next.
    • The Place all migrated virtual disks on the same SR option is selected by default and displays the default shared SR on the destination pool.
    • Select Place migrated virtual disks onto specified SRs to specify an SR from the Storage Repository list. This option allows you to select different SR for each virtual disk on the migrated VM.
  5. On the Networking page, map the virtual network interfaces in the selected VM to networks in the destination pool or server. Specify your options using the Target Network list and select Next.
  6. Select a storage network on the destination pool that is to be used for the migration of the VM’s virtual disks. Select Next.

    Note:

    Due to performance reasons, it is recommended that you do not use the management network for live migration.

  7. Review the configuration settings and select Finish to start migrating or moving the VM.

If you are migrating from an older version of XenServer or Citrix Hypervisor, you might need to restart all VMs after migrating your VMs, to ensure that new virtualization features are picked up.

XenServer 8

Citrix Hypervisor 8.2 Cumulative Update 1

Migrate Virtual Machines