I spent some time this week working on a demonstration of getting VNX block performance and configuration data into vCenter Operations for a customer. This scripts are very similar in function to the scripts that Clinton Kitson (fellow vSpecialist) wrote for the Hands On Labs at VMworld 2011 in Las Vegas. Mine are a little different in the following ways:
- These scripts measure and report block performance only
- These scripts pull in every metric that navicli can pull in
- These scripts do *not* use Hyperic or any temporary files to post the data - its directly sucked in from memory
- These are entirely in PowerShell
There are some things to note about these:
- There is no support for these. I will try to help you out if you have troubles, but these are NOT an official EMC product, just a demonstration of something cool.
- These are currently alpha quality at best - you are on your own if you rely on them for anything important.
- The script supports only 1 array at a time. I intend to change that, but for now thats the deal. If you need to collect stats for more than 1 array, run the scripts multiple times.
- Eventually these will be deprecated, whenever VMware comes out with a real adapter and not this hack :)
Install NaviCLI from PowerLink, and copy naviseccli.exe to the same directory you put this script. Ensure that statisics collection is enabled on your array.
Execute the with the following parameters:
.vnxvcops.ps1 -username <usernameforarray> -password XXXXXX -scope 0 -spaip <IP of SPA> -spbip <IP of SPB> -interval <Post interval in minutes> -URL http://<vcopsserverhostname>/HttpPostAdapter/OpenAPIServlet
When the script executes, it will display some progress information during the collection and posting process, and a quick output on every interval:
9/29/2011 8:38:22 PM : Post Completed - Sleeping 5 minutes before next post 9/29/2011 8:43:32 PM : Post Completed - Sleeping 5 minutes before next post 9/29/2011 8:48:41 PM : Post Completed - Sleeping 5 minutes before next post
What can you do in vCops with the data? How about this:
- Better error checking
- LUN/Type Aggregations
- Log to Event Log instead
- Run as a service?
- Support configuration file with multiple arrays
- Support reporting on VNX File (NFS/CIFS) statistics
Let me know if it works for you and other new features/bug fixes.