powercli

Powercli One-Liner to List ESXi Host UUID

June 6, 2016

I had to list the host UUID of all the ESXi hosts in an environment recently. This is just a quick post, to show how to grab this information using PowerCLI. After pointing the PowerCLI session at the relevent vCenter (or ESXi host), run the following: Get-VMHost | Select Name,@{n=”HostUUID”;e={$_.ExtensionData.hardware.systeminfo.uuid}} This results in listing each […]

0 comments Read the full article →

Quick Tip #2 Export VM Information From List

August 2, 2012

To export a list of virtual machine attributes, using a text file for input, we can use the following PowerCli code: Get-VM -Name (Get-Content c:\vmnames.txt) | Select Name,NumCpu,MemoryMB | Export-Csv C:\test.csv -NoTypeInformation -UseCulture

0 comments Read the full article →