We have a template for graphing LVS statistics. I noticed that there is a problem with this template. When virtual servers are added or deleted, the graphs get messed up because the indexes of the virtual servers change. The problem is that there is not one unique field that can be used for indexing. The virtual server index is not very useful since it is not always associated with the same virtual server, and the virtual server IP cannot be used since there may be several virtual servers with the same IP but different ports. What I would like is to use a combination of IP and port for indexing. I am trying to find out if this is possible to do in cacti. I found the <index_order> tag in the documentation, but I don't know if that can be used to accomplish what I want.
Here is how the snmp query looks at the moment:
Code: Select all
<interface>
<name>Get IPVS Statistics</name>
<oid_index>.1.3.6.1.4.1.8225.4711.17.1.1</oid_index>
<fields>
<srvIndex>
<name>Index</name>
<method>walk</method>
<source>value</source>
<direction>input</direction>
<oid>.1.3.6.1.4.1.8225.4711.17.1.1</oid>
</srvIndex>
<srvIP>
<name>Service IP</name>
<method>walk</method>
<source>value</source>
<direction>input</direction>
<oid>.1.3.6.1.4.1.8225.4711.17.1.4</oid>
</srvIP>
<srvSched>
<name>Scheduler</name>
<method>walk</method>
<source>value</source>
<direction>input</direction>
<oid>.1.3.6.1.4.1.8225.4711.17.1.2</oid>
</srvSched>
<srvPort>
<name>Service port</name>
<method>walk</method>
<source>value</source>
<direction>input</direction>
<oid>.1.3.6.1.4.1.8225.4711.17.1.5</oid>
</srvPort>
<srvBytesOut>
<name>Bytes out</name>
<method>walk</method>
<source>value</source>
<direction>output</direction>
<oid>.1.3.6.1.4.1.8225.4711.17.1.14</oid>
</srvBytesOut>
<srvBytesIn>
<name>Bytes in</name>
<method>walk</method>
<source>value</source>
<direction>output</direction>
<oid>.1.3.6.1.4.1.8225.4711.17.1.13</oid>
</srvBytesIn>
<srvPktsOut>
<name>Packets Out</name>
<method>walk</method>
<source>value</source>
<direction>output</direction>
<oid>.1.3.6.1.4.1.8225.4711.17.1.12</oid>
</srvPktsOut>
<srvPktsIn>
<name>Packets In</name>
<method>walk</method>
<source>value</source>
<direction>output</direction>
<oid>.1.3.6.1.4.1.8225.4711.17.1.11</oid>
</srvPktsIn>
<srvConnects>
<name>Connections</name>
<method>walk</method>
<source>value</source>
<direction>output</direction>
<oid>.1.3.6.1.4.1.8225.4711.17.1.10</oid>
</srvConnects>
<srvRealServers>
<name>Real Servers</name>
<method>walk</method>
<source>value</source>
<direction>output</direction>
<oid>.1.3.6.1.4.1.8225.4711.17.1.9</oid>
</srvRealServers>
</fields>
</interface>