UUID

vSphere IDs: The Ultimate Quick Reference Guide

Posted on Updated on


Ever feel like youโ€™re drowning in a sea of GUIDs and MoRefs? When youโ€™re scripting or troubleshooting, using the wrong ID is the fastest way to break a backup job or target the wrong server.

Here is the “Lazy Admin” breakdown of the most common vSphere identifiers and how to grab them with PowerCLI.


1. vCenter Instance UUID (serverGuid)

This is the “SSN” of your vCenter server. Itโ€™s generated at install time and stays durable for that instance.

  • Why it matters: In Linked Mode or cross-vCenter environments, this identifies which vCenter owns an object.
  • PowerCLI:PowerShell$vcenter = Connect-viserver vcsa-01a.corp.local $vcenter.InstanceUuid

2. ESXi Host UUID

Unlike other IDs, this isn’t generated by VMware. Itโ€™s pulled from the hardware’s SMBIOS.

  • Why it matters: Itโ€™s unique to the physical motherboard/vendor.
  • PowerCLI:PowerShell(Get-VMHost | Select -First 1).ExtensionData.hardware.systeminfo.uuid

3. VC-VM Instance UUID (The “Management” ID)

Found in the .vmx file as vc.uuid. This is what vCenter uses to track VMs.

  • The “Magic”: vCenter actively scans for duplicates of this ID and will “patch” (change) it automatically if it finds a conflict within its own inventory.
  • PowerCLI:PowerShell(Get-VM | Select -First 1).extensiondata.config.InstanceUUID

4. VM SMBIOS UUID (The “Guest” ID)

Found as uuid.bios in the .vmx. This is what the Guest OS (Windows/Linux) sees as the hardware serial number.

  • The “Magic”: vCenter tries not to change this because many applications use it for licensing. If you move/copy a VM, vCenter will ask you what to do to prevent duplicates.
  • PowerCLI:PowerShell(Get-VM | Select -First 1).extensiondata.Config.UUID

5. VM Location ID

Stored as uuid.location. This is a hash of the VMโ€™s configuration file path and the ESXi host UUID.

  • The “I Moved It” Prompt: When this hash doesn’t match the current environment, vSphere triggers that famous “Did you move it or copy it?” popup.
  • PowerCLI:PowerShell(Get-VM | Select -First 1).extensiondata.config.LocationId

6. VM MoRef (Managed Object Reference)

The MoRef is the “Short ID” (like vm-43) used by the API and the vCenter database.

  • Why it matters: This is the most important ID for database associations (stats, events, tasks). It is not unique across different vCenters.
  • PowerCLI:PowerShell(Get-VM | Select -First 1).ExtensionData.Moref.Value

Quick ID Reference Table

ID NameScopePersistenceBest Use Case
MoRefSingle vCenterChanges if re-inventoriedAPI calls & DB tracking
Instance UUIDSingle vCenterHigh (Patched by VC)Unique VM tracking
SMBIOS UUIDGlobal/Guest OSVery HighGuest Software Licensing
Host UUIDPhysical HardwarePermanentHardware Asset Tracking