(It used "rsh <filer> df"s to gather data.. I've considered making it use SNMP, but am currently an SNMP ignoramus and would have to learn it... would this be important to people?)
Trust me. It's worth your time to learn basic snmp stuff (ie it will make your life easier). I don't use any of the snmp trap stuff. I just use "snmpget" when I need to get information.
Here's an example of using snmpget to get the disk space available on a small toaster:
rootd 80> ./snmpget -a fs22:snmp:udp 1.3.6.1.4.1.789.1.5.4.1.4.1 1.3.6.1.4.1.789.1.5.4.1.4.1: INTEGER: 26183144 rootd 81> ./snmpget -a fs22:snmp:udp 1.3.6.1.4.1.789.1.5.4.1.3.1 1.3.6.1.4.1.789.1.5.4.1.3.1: INTEGER: 27421288
The "26183144" is the disk space used. The "27421288" is the disk space available. Here's the "df" output for comparison:
<root./pub/generic/wks/adm: 169> rsh fs22 df Filesystem kbytes used avail capacity Mounted on / 27421288 26183144 1238144 95% / /.snapshot 0 56 0 ---% /.snapshot
Which one is easier to parse? Especially when there's a snmpget perl library which will throw "27421288" right into a scalar variable for you. No need for rsh parsing, no need to deal with "if the server is down and my cron job rsh's to the server every 5 minutes..."
Of course, this all works because Netapp has a good MIB for fileservers, with CPU and filesystem space info.
In short, the snmp docs are scary. Ignore them. Just spend a day with the snmp FAQ, build snmpget (sorry, I can't remember the site where I got libSNMPt from, gawd, you think the distribution would have a README file or something). Learn how to use snmpget from the command line and from perl.
Then all you need to do is figure out which MIB number to use (ie that wierd 1.3.6.1.4.1.789.1.5.4.1.4.1 refers to a specific piece of data). If you check the archives of this mailing list, you'll find an email from me with a translation of most of the netapp ONTAP4 MIB. The guy at Netapp working on the MRTG stuff should know some good MIB numbers too.
Oh, did I mention that using snmp will make your life easier? :-)
Darrell Root rootd@nas.nasa.gov