Hi -
i've tried modifiying one of the snmp plugins to get disk I/O stats on linux
boxes. I've followed the advice of previous posts and installed my own script
on the target and am querying it via snmp.
I am able to get zenmodeler to detect the disks and they show up in the
Hardware tab of the device. The problem is that I have no idea which key/value
pairs are supposed to be in the map that the plugin returns. I don't know what
the format of the snmp index is supposed to be, etc...
I have a feeling that I my plugin return value is wrong because when I try to
associate a template to with the disk drive I get a failure. When doing this
in the GUI it just hangs indefinitely.
I don't see anything in the logs, etc...
snmpGetTableMaps = (
GetTableMap('partitionTable', '.1.3.6.1.4.1.2021', {
'.54': 'snmpindex',
'.55': 'id',
'.56': 'disk',
}
),
)
def process(self, device, results, log):
"""collect snmp information from this device"""
log.info('processing %s for device %s', self.name(), device.id)
getdata, tabledata = results
dtable = tabledata.get("partitionTable")
getdata, tabledata = results
if not dtable: return
rm = self.relMap()
for disk in dtable.values():
om = self.objectMap(disk)
if isinstance(om.disk, str):
if not re.search('^[hs]d[a-z]$', om.disk): continue
else:
continue
om.id = self.prepId(om.disk)
rm.append(om)
return rm
-------------------- m2f --------------------
Read this topic online here:
http://forums.zenoss.com/viewtopic.php?p=26312#26312
-------------------- m2f --------------------
_______________________________________________
zenoss-users mailing list
[email protected]
http://lists.zenoss.org/mailman/listinfo/zenoss-users