This is a quick post detailing a very quick/dirty script I knocked up using snmpwalk to probe my QSAN P300Q-D212 iSCSI SAN.
The reason behind it was because during a RAIDset rebuild or long running operation it seemed to take the web-based admin screens a long time to update/load, which was frustrating if you just wanted to pull out ‘Just show me rebuild status’ and nothing else please. – Which is very quick using SNMP.
So I decided to used the QSAN-SNMP.mib alongside snmpwalk to pull out the specific stats/statuses I was interested in, and where appropriate dump them into a bash array that I could iterate through to pull out multiple different statuses to give me a shell based table. (which needs some more work, – I might bump the scripts over to ncurses at some point to make things ‘pretty’).
I’m going to make these available on sourceforge for people to pull down. There are only 2 files which will need editing, at the top of each file is a COMMUNITY and QSANIP variable that needs setting appropriately for your environment.
I’m on Mac OSX so I downloaded the QSAN mib from the storage appliance itself and copied it into /usr/share/snmp/mibs.
Theres a couple of pros to this approach too, with some modification you could also use SNMP to set some storage options on the Storage Array, which might be useful, if you wanted to run a snapshot or something of the sort external to the Array, if an event happens then perform action ‘X’. Also, in its current incarnation you can plumb some of the statuses into a external monitoring application like Zabbix or Nagios. One thing which I was disappointed wasn’t featured in the QSAN MIB for the Array was disk I/O or overall Array I/O performance statistics, hopefully the guys at QSAN will make this available in a future update.
Anyhow, you can grab the shell files from here..
[amazon asin=B008VOKEZI&template=Iframe Image]
Matt Palmer 23 July 2012