Skip to main content

Powershell - how to get virtual machine GUID / ID (easiest way) from the hypervisor

Today, easy thing to manage, but of course - if you now how to do it.
To get VM ID from hypervisor, for example - to manage virtual machine from the powershell direct - you need to run simple command in the administrator session:

(get-vm virtualmachinename).id