Re: Varying table index for disk I/O stats
Gandalf <[email protected]>
| Newsgroups | gmane.network.cacti.user |
|---|---|
| Message-ID | <[email protected]> |
In case this is the latest XML, you are quite correct. A similar problem occurred on the disk space data query. I solved it by making the description the relevant index; in this case it would be hrDiskIODescr. Then, Cacti will look for changes of this string for a reindex operation. This is from memory, not tested. In case you are able to verify, please post your results to update this data query in the repository Reinhard On 19.05.2013 13:58, Brian Candler wrote: > [0.8.7i from Ubuntu 12.04 package] > > I am monitoring disk I/O stats using > http://docs.cacti.net/usertemplate:data:host_mib:diskio > > The SNMP query template is at the end of this mail. Here's an example of the > data it's collecting: > > $ snmpwalk -On -v2c -c XXXXXX XXXXXX 1.3.6.1.4.1.2021.13.15.1.1 | grep '\.55 ' > .1.3.6.1.4.1.2021.13.15.1.1.1.55 = INTEGER: 55 > .1.3.6.1.4.1.2021.13.15.1.1.2.55 = STRING: md127 > .1.3.6.1.4.1.2021.13.15.1.1.3.55 = Counter32: 2775494144 > .1.3.6.1.4.1.2021.13.15.1.1.4.55 = Counter32: 1303653888 > .1.3.6.1.4.1.2021.13.15.1.1.5.55 = Counter32: 12228936 > .1.3.6.1.4.1.2021.13.15.1.1.6.55 = Counter32: 1514190 > .1.3.6.1.4.1.2021.13.15.1.1.9.55 = INTEGER: 0 > .1.3.6.1.4.1.2021.13.15.1.1.10.55 = INTEGER: 0 > .1.3.6.1.4.1.2021.13.15.1.1.11.55 = INTEGER: 0 > .1.3.6.1.4.1.2021.13.15.1.1.12.55 = Counter64: 5680722259456 > .1.3.6.1.4.1.2021.13.15.1.1.13.55 = Counter64: 645548748288 > > This works fine, except for the following issue. > > Suppose I decide to monitor stats for device "md127". Cacti internally maps > this to the table row number, say x=55 as shown above. > > At some point in the future, perhas due to reboot or device insertion or > removal, the table may change. For example, md127 may become x=54. > > When this happens, Cacti starts graphing the wrong value (or no value at > all). But if I browse Graph management, it does show that it is monitoring > the wrong attribute (e.g. it shows "sdz" instead of "md127") > > To correct the problem, I have to go to Devices and click "(Verbose Query)" > next to "SNMP - Get Disk IO", or delete and recreate the graph. But of > course, it's not until I realise there's a problem that I do this, and a lot > of wrong data may have been recorded. > > Anyway, as far as I can tell, Cacti has made a sticky decision that it > should be monitoring row x=55. Is it possible to make it instead store that > it should be monitoring "md127" and map this to SNMP table index on every > query? > > Thanks, > > Brian Candler. > > --------- disk_io.xml --------- > <interface> > <name>Get Disk IO Information</name> > <index_order_type>numeric</index_order_type> > <oid_index>.1.3.6.1.4.1.2021.13.15.1.1.1</oid_index> > <fields> > <hrDiskIOIndex> > <name>Index</name> > <method>walk</method> > <source>value</source> > <direction>input</direction> > <oid>.1.3.6.1.4.1.2021.13.15.1.1.1</oid> > </hrDiskIOIndex> > <hrDiskIODescr> > <name>Description</name> > <method>walk</method> > <source>value</source> > <direction>input</direction> > <oid>.1.3.6.1.4.1.2021.13.15.1.1.2</oid> > </hrDiskIODescr> > <hrDiskIONRead> > <name>Number of Bytes Read</name> > <method>walk</method> > <source>value</source> > <direction>output</direction> > <oid>.1.3.6.1.4.1.2021.13.15.1.1.3</oid> > </hrDiskIONRead> > <hrDiskIONWrite> > <name>Number of Bytes Written</name> > <method>walk</method> > <source>value</source> > <direction>output</direction> > <oid>.1.3.6.1.4.1.2021.13.15.1.1.4</oid> > </hrDiskIONWrite> > <hrDiskIOReads> > <name>Number of Read accesses</name> > <method>walk</method> > <source>value</source> > <direction>output</direction> > <oid>.1.3.6.1.4.1.2021.13.15.1.1.5</oid> > </hrDiskIOReads> > <hrDiskIOWrites> > <name>Number of Write accesses</name> > <method>walk</method> > <source>value</source> > <direction>output</direction> > <oid>.1.3.6.1.4.1.2021.13.15.1.1.6</oid> > </hrDiskIOWrites> > </fields> > </interface> > > > ------------------------------------------------------------------------------ > AlienVault Unified Security Management (USM) platform delivers complete > security visibility with the essential security capabilities. Easily and > efficiently configure, manage, and operate all of your security controls > from a single console and one unified framework. Download a free trial. > http://p.sf.net/sfu/alienvault_d2d > _______________________________________________ > cacti-user mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/cacti-user > ------------------------------------------------------------------------------ AlienVault Unified Security Management (USM) platform delivers complete security visibility with the essential security capabilities. Easily and efficiently configure, manage, and operate all of your security controls from a single console and one unified framework. Download a free trial. http://p.sf.net/sfu/alienvault_d2d