Data queries and multiple indexes

Post general support questions here that do not specifically fall into the Linux or Windows categories.

Moderators: Developers, Moderators

Post Reply
stekut
Posts: 18
Joined: Wed Nov 15, 2006 5:14 am

Data queries and multiple indexes

Post by stekut »

Hi all,

I didn't found the solution on the forum so I start this thread.
I'm working on Nokia Checkpoint FW statistics.
I created my data_query xml file like this :

Code: Select all

<nokia-fwStats>
  <name>Get SNMP FW Statistics</name>
  <description>Queries a host for a list of FW statistics</description>
  <oid_index>.1.3.6.1.4.1.2620.1.1.25.5.1.1</oid_index>
  <oid_index_parse>OID/REGEXP:.*\.([0-9]*.0)$</oid_index_parse>
  <index_order>fwIfName:fwIfIndex</index_order>
  <index_order_type>numeric</index_order_type>

  <fields>
    <fwIfIndex>
      <name>Index (CHECKPOINT-MIB)</name>
      <method>walk</method>
      <source>value</source>
      <direction>input</direction>
      <oid>.1.3.6.1.4.1.2620.1.1.25.5.1.1</oid>
    </fwIfIndex>
    <fwIfName>
      <name>Name (CHECKPOINT-MIB)</name>
      <method>walk</method>
      <source>value</source>
      <direction>input</direction>
      <oid>.1.3.6.1.4.1.2620.1.1.25.5.1.2</oid>
    </fwIfName>
    <fwAcceptPcktsIn>
      <name>Accept Packets In</name>
      <method>walk</method>
      <source>value</source>
      <direction>output</direction>
      <oid>.1.3.6.1.4.1.2620.1.1.25.5.1.5</oid>
    </fwAcceptPcktsIn>
    <fwAcceptPcktsOut>
      <name>Accept Packets Out</name>
      <method>walk</method>
      <source>value</source>
      <direction>output</direction>
      <oid>.1.3.6.1.4.1.2620.1.1.25.5.1.6</oid>
    </fwAcceptPcktsOut>
    <fwAcceptBytesIn>
      <name>Accept Bytes In</name>
      <method>walk</method>
      <source>value</source>
      <direction>output</direction>
      <oid>.1.3.6.1.4.1.2620.1.1.25.5.1.7</oid>
    </fwAcceptBytesIn>
    <fwAcceptBytesOut>
      <name>Accept Bytes Out</name>
      <method>walk</method>
      <source>value</source>
      <direction>output</direction>
      <oid>.1.3.6.1.4.1.2620.1.1.25.5.1.8</oid>
    </fwAcceptBytesOut>
    <fwDropPcktsIn>
      <name>Drop Packets In</name>
      <method>walk</method>
      <source>value</source>
      <direction>output</direction>
      <oid>.1.3.6.1.4.1.2620.1.1.25.5.1.9</oid>
    </fwDropPcktsIn>
    <fwDropPcktsOut>
      <name>Drop Packets Out</name>
      <method>walk</method>
      <source>value</source>
      <direction>output</direction>
      <oid>.1.3.6.1.4.1.2620.1.1.25.5.1.10</oid>
    </fwDropPcktsOut>
    <fwRejectPcktsIn>
      <name>Reject Packets In</name>
      <method>walk</method>
      <source>value</source>
      <direction>output</direction>
      <oid>.1.3.6.1.4.1.2620.1.1.25.5.1.11</oid>
    </fwRejectPcktsIn>
    <fwRejectPcktsOut>
      <name>Reject Packets Out</name>
      <method>walk</method>
      <source>value</source>
      <direction>output</direction>
      <oid>.1.3.6.1.4.1.2620.1.1.25.5.1.12</oid>
    </fwRejectPcktsOut>
    <fwLogIn>
      <name>Log Packets In</name>
      <method>walk</method>
      <source>value</source>
      <direction>output</direction>
      <oid>.1.3.6.1.4.1.2620.1.1.25.5.1.13</oid>
    </fwLogIn>
    <fwLogOut>
      <name>Log Packets Out</name>
      <method>walk</method>
      <source>value</source>
      <direction>output</direction>
      <oid>.1.3.6.1.4.1.2620.1.1.25.5.1.14</oid>
    </fwLogOut>
  </fields>
</nokia-fwStats>
I created my data query, my graphs template, my data templates
It works ! When I go to graph list for a specific device, I see my nokia interfaces and I can choose the graph I want choosing the interfaces and then select the graph type (Drop or Accept or Log...) - the same way we can add a graph for traffic interface in fact !

But now I have to add a new graph : Connection number.
It doesn't depend on interfaces (the counter is for the entire nokia) and the index is different.
I would like to use these 2 OID .1.3.6.1.4.1.2620.1.1.25.3.0 (fwNumConn) and .1.3.6.1.4.1.2620.1.1.25.4.0 (fwPeakNumConn), so now the index change from .1.3.6.1.4.1.2620.1.1.25.5.1.1 to .1.3.6.1.4.1.2620.1.1.25.

Is it possible to add a section in my xml file to include this news oids (and index) and add it in the same data query ?

My cacti version : 0.8.7e.

Thanks for your help.
User avatar
gandalf
Developer
Posts: 22383
Joined: Thu Dec 02, 2004 2:46 am
Location: Muenster, Germany
Contact:

Post by gandalf »

IN SNMP lingo, you are talking about using two different MIB tables in the same Cacti Data Query. In case both are sharing the same index, this is ok. See e.g. interface.xml which does the same.
If they are NOT sharing the same index, you'll have to create a second Data Query. Do you know the related documentation at http://docs.cacti.net?
Do you know the existing Checkpoint FW templates featured in the scripts and templates forum (and at the 4th link of my sig)?
R.
stekut
Posts: 18
Joined: Wed Nov 15, 2006 5:14 am

Post by stekut »

Thanks for your reponse.
Well I saw the firewall stats already existed after I created everything, doesn't matter, I'm a newbie with Cacti so it made me understand many things. (In the existing script/template, the connection part is not in the data query)

So I need to have the same index for my packets stats and connection stats.
Packets index : .1.3.6.1.4.1.2620.1.1.25.5.1.1
Connections index : .1.3.6.1.4.1.2620.1.1.25

Is it possible to use .1.3.6.1.4.1.2620.1.1.25 has the unique index and get both packets and connections in my data query (I don't think so)?

I saw your post with sum of snmp values but I don't understand how to link it with my problem...
User avatar
gandalf
Developer
Posts: 22383
Joined: Thu Dec 02, 2004 2:46 am
Location: Muenster, Germany
Contact:

Post by gandalf »

I'm not sure that we're talking 'bout the same thing. As I do not have access to FW1 any more, please provide snmpwalks for both of the OIDs from above.
R.
Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests