Migrating virtual machines
search cancel

Migrating virtual machines

book

Article ID: 311446

calendar_today

Updated On:

Products

VMware vCenter Server VMware vSphere ESXi

Issue/Introduction

This article provides instructions for migrating virtual machines and their virtual machine disks.

Environment


VMware vSphere ESXi 5.0
VMware vCenter Server 5.0.x
VMware vCenter Server 5.1.x
VMware vSphere ESXi 5.1

Resolution

Use migration with Storage vMotion to relocate a virtual machine’s configuration file and virtual disks while the virtual machine is powered on. You cannot change the virtual machine’s execution host during a migration with Storage vMotion.

Online migration through VMware vCenter Server via Storage vMotion

  1. Open the vSphere/vSphere Infrastructure Client and connect to your respective vCenter Server/VirtualCenter server.
  2. Select and display the virtual machine that is to be migrated in the host inventory.
  3. Right-click the virtual machine, and select Migrate from the context menu.
  4. Select Change datastore and click Next.
  5. Select a resource pool, if applicable, and click Next.
  6. Select the destination datastore:
    • To move the virtual machine configuration files and virtual disks to a single destination, select the datastore and click Next.
    • To select specific destinations for the configuration file and individual each virtual disk, click Advanced. In the Datastore column, select a destination for the configuration file and each virtual disk, and click Next.

  7. Select a desired destination disk format and click Next:

    • Same as Source
      Use the format of the original virtual disk. If you select this option for a Raw Device Mapping (RDM) in either physical or virtual compatibility mode, only the mapping file is migrated.

    • Thin-Provisioned
      Use the thin format to save storage space. A thin virtual disk uses only as much storage space as it needs for its initial operations. When the virtual disk requires more space, it can grow in size up to its maximum allocated capacity.
      This option is not available for RDMs in physical compatibility mode. If you select this option for a virtual compatibility mode RDM, the RDM is converted to a virtual disk. RDMs converted to virtual disks cannot be converted back to RDMs.

    • Thick
      Allocate a fixed amount of hard disk space to the virtual disk. The virtual disk in the thick format does not change its size and from the beginning occupies the entire datastore space provisioned to it. This option is not available for RDMs in physical compatibility mode. If you select this option for a virtual compatibility mode RDM, the RDM is converted to a virtual disk. RDMs converted to virtual disks cannot be converted back to RDMs through conventional means. For more information, see Converting a physical or virtual machine to a virtual machine that uses Raw Device Mapping (broadcom.com).

    Note: Disks are converted from thin to thick format or thick to thin format only when they are copied from one datastore to another. If you choose to leave a disk in its original location, the disk format is not converted, regardless of the selection made here.

  8. Review the page and click Finish. A task is created that begins the virtual machine's migration process.

 

Offline migration through VMware vCenter Server

  1. Open the VMware vSphere Client and connect to your respective vCenter Server.
  2. Select and display the virtual machine that is to be migrated in the host inventory.
  3. Shut down the virtual machine guest operating system, powering off the virtual machine.
  4. Right-click the virtual machine, and select Migrate from the context menu.
  5. Select Change datastore and click Next.
  6. Select a resource pool, if applicable, and click Next.
  7. Select the destination datastore:
    • To move the virtual machine configuration files and virtual disks to a single destination, select the datastore and click Next.
    • To select specific destinations for the configuration file and individual each virtual disk, click Advanced. In the Datastore column, select a destination for the configuration file and each virtual disk, and click Next.

  8. Review the page and click Finish. A task is created that begins the virtual machine's migration process.