vCenter Cluster Performance Tool is a Powershell script that uses vSphere PowerCLI to obtain performance data for a cluster by aggregating information from individual hosts.
You have the following options to specify in the script.
- An “interval” of 20s or 300s. The default is 20s, and corresponds to real time statistics. 300s corresponds to the 5 min interval statistics.
- A stats query flag to obtain the list of counter IDs available on the vCenter Server. You can then pass the desired counter ID from that list to obtain Performance metrics for the cluster.
- Gathers all data of the specified interval type that is available on each host in the specified cluster
- Easy and a quick way of obtaining performance data for a vCenter cluster
- Data is saved in a CSV file, which can then easily be fed into any charting software
- A chart, in PNG format, is also generated for visualization
- VMware vCenter Server 5.0 and above
- PowerShell supporting Windows system (Windows XP and later)
- VMware vSphere PowerCLI that is compatible with the vCenter Server
- Microsoft Chart Controls for Microsoft .NET Framework 3.5
You need to install VMware PowerCLI and Microsoft Chart Controls. The PowerShell script does not need additional installation.
2. Before Running
Once installed, you will need to modify the scripts to specify locations of files as follows.
Change $psCommand and $getHostStatsPrg to point to the location of powershell.exe and getHostStats.ps1 respectively.
Change $interval, if needed. This specifies the kind of Performance Statistics Samples to retrieve (in seconds) – either 20 (real-time, default), or 300 (5min samples).
Change $storeHostStats, $storeClsStats and $chartName to point to the locations of the individual host stats output file, aggregated cluster stats output file, and the performance chart file respectively.
You can list all available counterIds on your vCenter Server by passing -1 for the counterId argument to getClusterStats.ps1.
From that list you can pass the desired counterId to the same argument to retrieve Performance Statistics for the given cluster. Note that not all of those counterIds may be available for a cluster object. Please refer to the VMware vSphere Web Services SDK Documentation for details on this topic.