This document contains official content from the BMC Software Knowledge Base. It is automatically updated when the knowledge article is modified.
BMC Discovery 11.3
How is the relationship between an ESX server and its hosted VMs created ?
How to know which ESX server is associated with a VMWare VM ?
What to do if no relationship is created between an ESX server and its hosted VMs?
See "Linking from the Virtual Host" in https://docs.bmc.com/docs/display/Configipedia/VMware+Virtual+Machine+software :
"When a host is scanned we check the serial number to see if it contains the string "VMware-", if it does then we know it is a virtualised host using VMware technology. We then set an attribute on the host called "virtual", which can be used in the future to easily identify virtual hosts.
We then extract the value found after the "VMware-" string, this value corresponds to the uuid found in the .vmx file or obtained from command execution (in case of ESXi Server VMs).
Finally we perform a search on the Datastore to see if we can find a Software Instance which has a vm_uuid equal to the extracted information from the serial on the host.
If we find a Software Instance then we link them together using a HostContainment relationship with the SI taking the part of the HostContainer and the Host taking the part of the ContainedHost. This relationship has a specific type 'VMware' assigned to it."
If no relationship is created between an ESX server and its hosted VMs, check if serial number and UUID are discovered for the hosted VMs. If not, check that the VMs were scanned with sufficient permissions.
For example, on a Linux host, it may be necessary to configure sudo to be able to run dmidecode and retrieve a serial number. For more information, see https://docs.bmc.com/docs/discovery/113/adding-privileged-execution-to-commands-788110990.html .