VMware ESXi and vSphere Cluster Management
vSphere vMotion Explained: Live Virtual Machine Migration in VMware ESXi
Learn how vSphere vMotion moves running virtual machines between ESXi hosts, including migration phases, requirements, maintenance workflows, compatibility checks, and troubleshooting.
vSphere vMotion is VMware vSphere's live migration technology. It moves a powered-on virtual machine (VM) from one ESXi host to another while the guest operating system and applications continue running. An ESXi host is the physical virtualization server that supplies CPU, memory, networking, and other resources to VMs.
In a successful migration, the workload's compute execution changes hosts without requiring the guest OS to shut down and boot again. This makes vMotion especially useful for planned ESXi maintenance, workload balancing, and moving a VM away from a busy host.
What vMotion Moves
During a compute migration, vMotion transfers the active state required for the VM to continue on the destination host. This includes:
- The VM's active memory contents.
- CPU execution state and other processor state needed to resume execution.
- Virtual machine configuration and identity information needed by the destination host.
- Virtual devices and firmware-related settings.
- The virtual network adapter identity, including its virtual MAC address.
The guest OS, running processes, and applications remain the same running instance. vMotion is not the same as shutting down a VM, copying its files, and starting a new instance elsewhere.
For compute-only vMotion, the VM's virtual disks remain on shared storage that both hosts can access. The destination host opens the same virtual disks after the VM's execution state has moved.
Service Continuity and User Impact
Applications can continue serving users because the VM remains powered on while most of its memory state is copied. Preserving the VM's virtual network identity also allows active network sessions to remain available in the normal case.
The phrase no downtime should be treated as an operational goal rather than an unconditional guarantee. vMotion includes a short switchover: the source briefly stops VM execution, transfers the remaining changed state, and starts execution on the destination. A successful switchover is normally brief, but network congestion, incompatible hardware, resource shortages, or an operation failure can affect the migration.
How a vMotion Operation Works
Several components participate in a typical operation:
- Source host: The ESXi host currently running the VM.
- Destination host: The ESXi host that will run the VM after migration.
- vCenter Server: The centralized vSphere management component that validates and orchestrates the operation.
- VMkernel adapters: ESXi networking interfaces configured for host services such as vMotion.
- vMotion network: The network path used to transfer memory and execution state between hosts.
- VM: The powered-on workload being relocated.
- Shared storage: Storage accessible to both hosts for compute-only migration.
- Validation: vCenter Server checks host compatibility, capacity, storage visibility, networking, VM configuration, and other rules.
- Initial memory copy: The source host copies the VM's memory pages to the destination while the VM continues running.
- Changed-page copying: As the VM runs, applications and the guest OS modify memory pages. The source repeatedly sends those changed pages to the destination.
- Switchover: When the remaining changed state is small enough, the source briefly pauses execution, transfers the final state, and hands control to the destination.
- Destination activation: The destination resumes the VM, reconnects its virtual devices and networks, and continues execution.
- Source cleanup: After successful activation, the source host releases its execution state and vCenter Server updates the VM's placement.
Completion time depends on the VM's memory size, its rate of memory modification, available vMotion bandwidth, network latency, source and destination host load, and other concurrent migrations. A database or analytics VM with high memory churn may keep changing pages faster than the network can transfer them, making the operation slow or difficult to complete.
vMotion Process Phases
Migration Types and Scope
A VM can often move between eligible hosts in the same cluster. Depending on licensing, versions, configuration, and compatibility, vSphere can also support migrations between eligible hosts outside the same cluster. Do not assume that physical reachability alone makes such a migration valid; the wizard's compatibility checks must pass.
An administrator can start a manual migration for a selected VM. Automated workflows can also use vMotion. For example, DRS—Distributed Resource Scheduler—can recommend or automate placement changes to balance cluster resources, subject to its automation level and rules. See DRS automation levels for related configuration.
vMotion Prerequisites Checklist
CPU generations do not always expose identical instruction sets. Enhanced vMotion Compatibility (EVC) establishes a common CPU feature baseline for hosts in an eligible cluster, improving migration compatibility. EVC does not make every hardware feature interchangeable; review the specific compatibility result. See EVC explained and CPU compatibility for vMotion.
Configuring the Environment
- Create or identify a VMkernel adapter on each ESXi host.
- Enable the vMotion service on the relevant VMkernel adapters.
- Provide end-to-end connectivity between the source and destination vMotion interfaces according to the network design.
- Use consistently configured standard or distributed virtual networking so the destination can connect the VM to every required port group. See distributed switches and standard switches.
- Verify datastore visibility from both hosts for compute-only migration.
- Configure or validate EVC when processor generations require a common baseline.
A dedicated, adequately sized vMotion network reduces contention with management, storage, and VM traffic. Monitor bandwidth, latency, packet errors, and switch configuration; a nominally configured interface is not sufficient if the physical path is congested or inconsistent.
Planned ESXi Maintenance Workflow
Hardware maintenance is a central vMotion use case. For example, an ESXi host may need a fan or power component replaced.
- Identify the host that requires maintenance and inventory its running VMs.
- Confirm that other hosts have enough CPU and memory capacity, compatible CPU capabilities, datastore visibility, and matching virtual networks.
- Migrate each eligible production VM away from the affected source host.
- Verify that each VM is powered on, reachable, and running on a destination host.
- Place the empty host into maintenance mode, which is the host state used to evacuate workloads before planned work. Review maintenance mode for related behavior.
- Perform the hardware work, including powering down the host if the procedure requires it.
- Return the repaired host to service and confirm that it is connected and healthy.
- Optionally rebalance workloads or return selected VMs, after repeating compatibility and capacity checks.
vMotion reduces planned application interruption, but it does not replace maintenance planning. Validate backups, application health, network dependencies, capacity headroom, and rollback procedures before evacuating a production host.
Manual vSphere Client Workflow
- In the vSphere Client, select the powered-on VM.
- Choose the migration action.
- Select the workflow to change the compute resource. Do not select a storage-only workflow when the goal is only to change hosts.
- Select an eligible destination ESXi host or cluster.
- Review the destination networks and other placement choices.
- Read every compatibility warning and review the migration validation results.
- Finish the workflow only after resolving blocking errors or consciously evaluating nonblocking warnings.
- Monitor Recent Tasks, VM events, host events, and performance metrics until the operation completes.
- After completion, verify the VM power state, host placement, application reachability, virtual network connections, and CPU and memory usage.
Common Compatibility Issues
Troubleshooting vMotion
Destination host is incompatible
Read the detailed compatibility message instead of relying only on the final task summary. Compare CPU features, available CPU and memory, datastore visibility, destination port groups, attached devices, and special VM or host capabilities. Select another destination, correct the missing configuration, or establish an appropriate EVC baseline before retrying.
Hosts cannot communicate over the migration network
Verify that vMotion is enabled on a VMkernel adapter on both hosts. Check VMkernel IP addresses, VLAN assignments, uplinks, routing or Layer 2 reachability, MTU settings, firewall policies, switch configuration, and physical link health. Use supported host-to-host VMkernel connectivity tests for the installed vSphere version. Repair the complete network path before retrying.
Migration remains in progress
Review VM and host performance metrics, vMotion throughput, network errors, and host contention. Compare the VM's memory size and active memory write rate with available migration bandwidth. If possible, lower application activity, schedule the move during a quieter period, improve vMotion network capacity, or select a less-loaded destination.
Application connectivity changes after migration
Confirm that the VM's destination port group maps to the intended network and that VLAN access, uplinks, distributed-switch membership, and security policies are consistent. Test guest connectivity and application listeners, and check external network policies. Validate the configuration with a noncritical VM before migrating production workloads.
Limitations and Planning Notes
- Not every VM and host pair is eligible for live migration.
- CPU compatibility, passthrough devices, local-resource dependencies, networking differences, and capacity limits are common blockers.
- Large memory footprints and high memory write rates can make pre-copy take longer or prevent it from converging quickly.
- The destination must support every virtual network to which the VM is connected.
- Compute-only vMotion depends on shared datastore access; when storage is not shared, use a migration method that includes storage relocation.
- Use dedicated and adequately sized vMotion networking, and avoid congestion during planned moves.
- Monitor the VM and application after migration rather than assuming a successful task means every dependency is healthy.
Exam-Relevant Summary
- vMotion is live migration of a powered-on VM between ESXi hosts.
- The memory pre-copy phase transfers memory while the VM continues running.
- The switchover briefly pauses execution, transfers remaining state, and resumes the VM on the destination.
- Compute-only vMotion changes the host but normally leaves virtual disks on shared storage.
- vCenter Server, compatible hosts, vMotion-enabled VMkernel networking, destination capacity, CPU compatibility, matching VM networks, and required datastore access are core prerequisites.
- EVC provides a common CPU feature baseline when eligible hosts have different processor generations.
- Storage vMotion moves virtual disks and is distinct from basic compute-host vMotion.
- DRS can recommend or automate placement changes that use vMotion, while an administrator can also initiate a migration manually.