VMware Infrastructure Toolkit – PowerShell Scripting

Powergui

Microsoft PowerShell scripting is a must-know for supporting VMware.

After spending days evaluating products that would report virtual infrastructure capacity to my liking and that were affordable, I opted to write my own reporting and capacity planning application using PowerShell scripts and Excel.

 Using PowerGUI and VI Toolkit for PowerShell I created two scripts: one script queries the Virtual Center for data storage capacity and utilization. The second script queries for VM to host capacity and memory – CPU metrics. The information is saved to a .CSV files once a week.

 

Using Excel, I import the .CSV files into my VM Dashboard (Excel) and run calculations for each VM environment (DEV, QA, Prod). To enhance the look of the dashboard, I have thrown in graphs to show resource utilization and a trending graph.

 

The VM dashboard has been well received by managers and those who want to follow week-by-week changes and usage of the virtual infrastructure. It also helps to proactively grow the VI because we can see the weekly growth of each environment and know in advance to add more storage or other server resources.

To get started writing PowerShell scripts or to borrow scripts already written visit the VMware VMTN blog for PowerShell.

2 Comments

  1. ron

Leave a Reply