Unable to access the specified host. It either does not exist, the server software is not responding, or there is a network problem.
[YYYY-MM-DD hh:mm:ss.283 01624 warning 'App' opID=#######-#######] [MoDVSwitch::UpdateHostNetworkSummaryOnDvsDestroy] Invalid host member [host-###] found in the vDS. [YYYY-MM-DD hh:mm:ss.295 01624 error 'App' opID=#######-########] [MoDVSwitch::HostCallPreFlightCheckInt] DVS.ConfigSpec.host[host-###].host not registered in vmom
Warning: These steps should not be used in environments using vCloud Director.
Caution: These steps are for vCenter Server using a Microsoft SQL database or vPostgres.
Please consult a Broadcom Support Engineer before performing these steps. For more information, please see Creating and managing Broadcom support cases
Important: Ensure a non-memory vCenter snapshot is taken for a standalone vCenter. If the vCenter is in ELM, ensure to take offline snapshots for all the vCenters that are in linked mode.
To manually remove an ESXi 7.x and 8.x host from the vCenter Server database:
service-control --stop vmware-vpxd
Connect to the vCenter Server vPostgres database:/opt/vmware/vpostgres/current/bin/psql -d VCDB -U postgres
select ID from VPX_ENTITY where name ='<esxi host name>';
delete from vpx_ds_assignment where entity_id in (select id from vpx_vm where host_id = #####);
delete from vpx_nw_assignment where entity_id in (select id from vpx_vm where host_id = #####);
select id from vpx_vm where host_id = #####;
delete from vpx_dvhost where host_id = #####;
delete from vpx_dvport_membership where host_id = #####;
delete from vpx_dvs_blob where host_id = #####;
delete from vpx_host where id = #####;
vpx_host_x
vpx_host_vm_config_option
vpx_compute_resource_dpm_host
vpx_host_cpu
vpx_host_node
vpx_host_node_cpu
vpx_host_pci_device
vpx_host_cpu_thread
vpx_host_cpu_cpuid_feature
delete from vpx_entity where id = #####;
delete from vpx_entity where parent_id = #####;
delete from vpx_entity where id = #####;
\q
service-control --start vmware-vpxd
In case the ESXi Host is a standalone host (not part of a cluster), additional steps need to be taken to avoid a situation where a standalone compute resource is left without a host.
To remove a standalone ESXi Host from the vCenter Database:
service-control --stop vmware-vpxd
Connect to the vCenter Server vPostgres database:/opt/vmware/vpostgres/current/bin/psql -d VCDB -U postgres
SELECT id, name FROM vpx_entity WHERE type_id = 2 and id not in (SELECT a.id FROM vpx_entity as A LEFT JOIN vpx_entity as B ON A.id = B.parent_id where a.type_id=2 and b.type_id=1 GROUP BY A.id);
Example Output:
id | name |
--------+--------------------------+---------+-----------
##### |<Resource name> |
##### |<Resource name> |
(2 rows)
delete from vpx_entity where parent_id = #####;
delete from vpx_entity where id = #####;
service-control --start vmware-vpxd