Agent can't send heartbeats because socket address structure initialization is failing
YYYY-MM-DDThh:mm:ssZ Er(163) Vpxa[2099707]: [Originator@6876 sub=Heartbeat opID=vpxaHeartbeat.cpp:218-117a92xx] getaddrinfo of server address failed; ' xxx.xx.x.xx', r: -2(Name or service not known)
Note: Before starting, see Restarting the Management agents on an ESX Server for important information on restarting the mgmt-vmware service.
There are two methods to get the ESXi hosts connected again. Try each one in the order specified, testing the results each time.
Before performing either method, ensure that the Managed IP Address of the vCenter Server is updated to reflect the new IP address being used. Also ensure that there are not any additional trailing whitespaces in the IP address. For more information, see Verifying the vCenter Server Managed IP Address.
vpxa.cfg
file on ESXi:
root
to the ESXi host with an SSH client. vpxa.cfg
file using a text editor and change the serverIp
parameter to the new IP of the vCenter Server.
vpxa.cfg
can be found here /etc/vmware/vpxa/vpxa.cfg
.
vpxa.cfg
file no longer exists, as the vpxa configuration was moved to the ESXi config store. Therefore, in the event this location /etc/vmware/vpxa/vpxa.cfg
cannot be found on ESXi 7.0, follow these steps instead:configstorecli config current get -c esx -g services -k vpxa_solution_user_config -outfile vpxa.json
rm -f vpxa.json.bak; cp vpxa.json vpxa.json.bak -f
<vcenter_ip>
with the correct IP address):sed -e 's/ "server_ip".*/ "server_ip": "<vcenter_ip>",/g' -i vpxa.json
configstorecli config current update -c esx -g services -k vpxa_solution_user_config -infile vpxa.json
configstorecli config current get -c esx -g services -k vpxa_solution_user_config
/etc/init.d/vpxa restart
In ESXi 8.0.1 and later, use the path and value arguments in configstorecli to update the vCenter IP address in ESXi config store.
Set the IP address using --path/-p and --value/-v arguments (replace <vcenter_ip> with the correct IP address):
configstorecli config current set -c esx -g services -k vpxa_solution_user_config --path /server_ip --value "<vcenter_ip>"
Verify path of vCenter IP address is set correctly using below command:
configstorecli config current get -c esx -g services -k vpxa_solution_user_config --path /server_ip
Restart vpxa to apply the change:
/etc/init.d/vpxa restart
Note: If method 1 does not work, apply method 2.
Note: Do not remove the ESXi host from vCenter inventory if the host is attached to a Distributed Switch (vDS). For more information, see Moving an ESX/ESXi host with vDS from one vCenter Server to another.
Check if the ESXi host keeps reconnecting continuously and "vpxa_solution_user_config
" is reverting back to old VC IP:
configstorecli config current get -c esx -g services -k vpxa_solution_user_config
Step 1: Verify Runtime settings for vCenter Server
To update the vCenter Server managed address, follow these steps:
Step 2: Restart the vCenter Server
After updating the vCenter Server managed address, restart the vCenter Server to apply the changes.
If an incorrect Managed IP Address is configured for VirtualCenter.AutoManagedIPV4 and VirtualCenter.AutoManagedIPV6
, the vCenter Server does not receive heartbeats from the ESX/ESXi host causing it to go into a disconnected state.
For related information, see Verifying the VirtualCenter Managed IP Address.