On 06 Jan 16:17, John Stoffel wrote:
"John" == John Constable jc18@sanger.ac.uk writes:
John> We've had some success using their API - I have python scripts John> that pull out network info and latency metrics into our graphite John> system. We are probably going to switch to this for our Nagios John> systems as we have seen the SNMP timeout under similar John> conditions.
John> I think you can get what you need from the diagnosis API, more John> specifically the diagnosis-alert-info, but I haven't tested it.
John> I do find that the API is much quicker than SNMP for bulk John> queries (all io stats for every volume, for example), and much John> more reliable. Its an area that rewards some time spent, IMHO..
Care to share your work with the rest of us, so we can all benefit? Or give pointers to the docs we need to read? I've got a cDOT setup which is crying out to be monitored and since our new Nagios instance might not cut it from what you say, having other options would be ideal.
Probably waaaay to late now (and apologies for that), but I have put the code up on GitHub; https://github.com/kript/Monitoring-Stuff/blob/master/Generate_NetApp_Perf_s...
Which means I can use it like this;
python Generate_NetApp_Perf_stats.py get-counter-values volume nfs_write_ops nfs_read_ops nfs_write_latency nfs_read_latency nfs_other_ops nfs_other_latency
to push Graphite IO stats for every volume on a (JSON deliminated file list of NetApp 7-Mode units).
or this;
python Generate_NetApp_Perf_stats.py get-counter-values ifnet recv_packets recv_errors send_packets send_errors collisions recv_data send_data recv_mcast
To generate network stats for the same.
It runs every minute and puts negligible load on the filer, and returns quickly (unlike SNMP).
Its not really written for portability, but shouldn't be hard to convert. Commenting out line 327 and uncommenting 326 will show you it in action, and changing the CARBON_SERVER variable to your Graphite system should be enough, once you have created your list of 7-Mode systems (and setup their API user).
Feel free to fork/improve/ignore.. :)