Check the total number of vCPU's assigned to virtual machines.
To use this script you have to install VMware vSphere PowerCLI.
- Start VMware vSphere PowerCLI
- Navigate to the directory where you saved the script
- Run
.\esxi-cpu-inventory.ps1 -server <server-ip>
PowerCLI> .\esxi_cpu_inventory.ps1 -server my-esxi.local
Host my-esxi.local has 1 vCPU's assigned to running VM's, out of 16 cores available. The number of total vCPU's assigned is 22.