vMotion of Virtual Machines fails when migrating between esxi hosts
vSphere ESXi 7.x
vSphere ESXi 8.x
Notes: For more information, see Creating a VMkernel port and enabling vMotion on an ESXi/ESX host. For best practices, see the Networking Best Practices for vSphere vMotion.
1. List the network interface with the following command:
esxcli network ip interface list
Sample output:
vmk0
Name: vmk0
MAC Address: ##:##:##:##:##:##
Enabled: true
Portset: vSwitch0
Portgroup: Management Network
Netstack Instance: defaultTcpipStack
VDS Name: N/A
VDS UUID: N/A
VDS Port: N/A
VDS Connection: -1
Opaque Network ID: N/A
Opaque Network Type: N/A
External ID: N/A
MTU: 1500
TSO MSS: 65535
RXDispQueue Size: 1
Port ID: 33554436
2. For each VMkernel adapter entry, run this command:
esxcli network ip interface tag get -i [VMkernel adapter name]
Example command:esxcli network ip interface tag get -i vmk0
Any adapters with tag value vMotion will be used for vMotion.
Sample vMotion VMKernel adapter value:
Tags: vMotion
3.An incorrect default gateway prevents cross-subnet communication across different clusters or layer 3 networks. Run the following command to check the IPv4 configuration and gateway for the vMotion adapter:
esxcli network ip interface ipv4 get -i <VMkernel_adapter_name>
Confirm that the configured default gateway matches the valid gateway used by other functional hosts on the same vMotion subnet. If the default gateway is incorrect, update it via the vSphere Client: Networking > VMkernel NICs > Edit settings > Edit IPv4 settings.
4.Run diagnostic tools between source and destination vMotion VMkernel adapters
vmkping commands
vmkping uses a VMkernel’s TCP/IP stack to send ICMP traffic to a destination host.
Consider a source vMotion VMkernel adapter vmk0 with IP address #.#.#.1 and a destination vMotion VMkernel adapter vmk0 with IP address #.#.#.2.
From source ESXi host, run this command:vmkping -I vmk0 #.#.#.2
Similarly, from destination ESXi host, run this command:vmkping -I vmk0 #.#.#.1
If Jumbo frame is enabled to 9000
vmkping -I vmk0 #.#.#.1 -s -d 8972
If the vMotion is configured on vMotion tcp/ip stack, run the below command:
vmkping -I vmk0 #.#.#.1 -S vMotion
Note: After creating a VMkernel adapter on the vMotion TCP/IP stack, only this stack can be used for vMotion on this host. The VMkernel adapters on the default TCP/IP stack are deactivated for the vMotion service, see Testing VMkernel network connectivity with the vmkping command.
5. With long distance vMotion, the maximum supported RTT is 150 milliseconds.
6. The netcat utility can be used to verify connectivity on a specific remote port. To run netcat use the following command:
nc
For example, consider a source vMotion VMkernel adapter vmk0 with IP address #.#.#.1 and a destination vMotion VMkernel adapter vmk0 with IP address #.#.#.2. Since vMotion listens on port 8000 of the vMotion VMkernel adapter, it is necessary to verify that a connection to port 8000 can be established.
From source ESXi host, run this command:
nc -z #.#.#.2 8000
From destination ESXi host, run this command:
nc -z #.#.#.1 8000
Sample successful output:
Connection to #.#.#.2 8000 port [tcp/*] succeeded!
7. For more information on nc and troubleshooting specific tcp/ip port connectivity issues, see: