[Solved] Indexed query issue / Stonesoft 5.3 template

Templates, scripts for templates, scripts and requests for templates.

Moderators: Developers, Moderators

User avatar
GLR
Cacti User
Posts: 55
Joined: Mon Jul 21, 2008 5:45 am
Location: Paris suburbs, France
Contact:

[Solved] Indexed query issue / Stonesoft 5.3 template

Post by GLR »

To get the working host template, go directly there : http://forums.cacti.net/viewtopic.php?p=218724#p218724


Hello,

I have difficulties to create an indexed query and don't find what's wrong or missing.

It is about the new StoneGate engine v5.3 firewall stats table (which is very close to CheckPoint one but with more values)

.iso.org.dod.internet.private.enterprises.stonesoft.stonesoftProducts.stonesoftFirewall.firewallObjects.fwIfTable

Image

Image

(Note : No reply is provided at fwIfStatsIndex)

stonegate-mibs-5.3 : https://my.stonesoft.com/support/attach ... bs-5.3.zip

Walk example :

Code: Select all

>snmpwalk -v2c -c com 10.1.29.5 .1.3.6.1.4.1.1369.5.2.1.10.1
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.2.1 = STRING: "eth0"
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.2.2 = STRING: "eth1"
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.2.3 = STRING: "eth2"
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.2.4 = STRING: "eth3"
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.2.5 = ""
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.3.1 = Counter64: 9847806
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.3.2 = Counter64: 10077556
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.3.3 = Counter64: 425076
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.3.4 = Counter64: 7205095
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.3.5 = Counter64: 0
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.4.1 = Counter64: 34123
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.4.2 = Counter64: 2
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.4.3 = Counter64: 4480
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.4.4 = Counter64: 15
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.4.5 = Counter64: 0
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.5.1 = Counter64: 115850
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.5.2 = Counter64: 2
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.5.3 = Counter64: 64180
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.5.4 = Counter64: 13461
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.5.5 = Counter64: 0
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.6.1 = Counter64: 0
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.6.2 = Counter64: 0
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.6.3 = Counter64: 0
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.6.4 = Counter64: 0
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.6.5 = Counter64: 0
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.7.1 = Counter64: 13
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.7.2 = Counter64: 0
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.7.3 = Counter64: 0
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.7.4 = Counter64: 0
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.7.5 = Counter64: 0
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.8.1 = Counter64: 575823517
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.8.2 = Counter64: 857155054
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.8.3 = Counter64: 49598813
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.8.4 = Counter64: 412553617
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.8.5 = Counter64: 0
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.9.1 = Counter64: 5256809
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.9.2 = Counter64: 152
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.9.3 = Counter64: 236155
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.9.4 = Counter64: 1346
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.9.5 = Counter64: 0
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.10.1 = Counter64: 0
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.10.2 = Counter64: 0
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.10.3 = Counter64: 0
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.10.4 = Counter64: 768
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.10.5 = Counter64: 0
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.11.1 = Counter64: 0
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.11.2 = Counter64: 0
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.11.3 = Counter64: 0
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.11.4 = Counter64: 0
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.11.5 = Counter64: 0
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.12.1 = Counter64: 780
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.12.2 = Counter64: 0
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.12.3 = Counter64: 0
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.12.4 = Counter64: 0
SNMPv2-SMI::enterprises.1369.5.2.1.10.1.12.5 = Counter64: 0
SNMP query XML file (cut) :

Code: Select all

<interface>
    <name>StoneSoft fwIfTable</name>
    <description>StoneGate firewall interface table stats</description>
    <oid_index>.1.3.6.1.4.1.1369.5.2.1.10.1.2</oid_index>
    <index_order>fwIfName</index_order>
    <fields>
        <fwIfStatsIndex>
            <name>Index</name>
            <method>walk</method>
            <source>value</source>
            <direction>input</direction>
            <oid>.1.3.6.1.4.1.1369.5.2.1.10.1.1</oid>
        </fwIfStatsIndex>
        <fwIfName>
            <name>Name</name>
            <method>walk</method>
            <source>value</source>
            <direction>input</direction>
            <oid>.1.3.6.1.4.1.1369.5.2.1.10.1.2</oid>
        </fwIfName>
        ...
Indexed query definition :

Image

Indexed query templates definition :

Image

Indexed query walk debug :

Image

Data template :

Image

Result : Faulty datasource :

Image

What's wrong ? It would be very kind if someone could help me...

PS : When completed, I will of course post the full templates...
Last edited by GLR on Thu Jan 16, 2014 12:54 pm, edited 5 times in total.
Cacti 0.8.8b + spine 0.8.8b
on Debian / Apache 2.2 / PHP 5.2 / MySQL 5.0
User avatar
Linegod
Developer
Posts: 1626
Joined: Thu Feb 20, 2003 10:16 am
Location: Canada
Contact:

Re: Indexed query issue

Post by Linegod »

You are attempting to get the fwIfStatsIndex index from .1.3.6.1.4.1.1369.5.2.1.10.1.1

Your walk of .1.3.6.1.4.1.1369.5.2.1.10.1 does not return anything under .1.3.6.1.4.1.1369.5.2.1.10.1.1

You will have to walk .1.3.6.1.4.1.1369.5.2.1.10.1.2 for fwIfStatsIndex, and use a regex to capture the portion after it:

.1.3.6.1.4.1.1369.5.2.1.10.1.2.{this value}

Read the documentation ( http://docs.cacti.net ) on how to do this, or take a look at some of the other templates.
--
Live fast, die young
You're sucking up my bandwidth.

J.P. Pasnak,CD
CCNA, LPIC-1
http://www.warpedsystems.sk.ca
User avatar
GLR
Cacti User
Posts: 55
Joined: Mon Jul 21, 2008 5:45 am
Location: Paris suburbs, France
Contact:

Re: Indexed query issue

Post by GLR »

Is it supposed to be better ?
It still doesn't work : Same result in the datasource...

Code: Select all

<interface>
    <name>StoneSoft fwIfTable</name>
    <description>StoneGate firewall interface table stats</description>
    <oid_index>.1.3.6.1.4.1.1369.5.2.1.10.1.2</oid_index>
    <oid_index_parse>OID/REGEXP:.*\.([0-9]*)$</oid_index_parse>
    <index_order>fwIfName</index_order>
    <fields>
        <fwIfStatsIndex>
            <name>Index</name>
            <method>walk</method>
            <source>value</source>
            <direction>input</direction>
            <oid>.1.3.6.1.4.1.1369.5.2.1.10.1.1</oid>
        </fwIfStatsIndex>
        <fwIfName>
            <name>Name</name>
            <method>walk</method>
            <source>value</source>
            <direction>input</direction>
            <oid>.1.3.6.1.4.1.1369.5.2.1.10.1.2</oid>
        </fwIfName>

Code: Select all

+ Running data query [44].
+ Found type = '3' [snmp query].
+ Found data query XML file at '/usr/share/cacti/resource/snmp_queries/StoneSoft_fwIfTable.xml'
+ XML file parsed ok.
+ Executing SNMP walk for list of indexes @ '.1.3.6.1.4.1.1369.5.2.1.10.1.2'
+ Index found at OID: '1.3.6.1.4.1.1369.5.2.1.10.1.2.1' value: 'eth0'
+ Index found at OID: '1.3.6.1.4.1.1369.5.2.1.10.1.2.2' value: 'eth1'
+ Index found at OID: '1.3.6.1.4.1.1369.5.2.1.10.1.2.3' value: 'eth2'
+ Index found at OID: '1.3.6.1.4.1.1369.5.2.1.10.1.2.4' value: 'eth3'
+ Index found at OID: '1.3.6.1.4.1.1369.5.2.1.10.1.2.5' value: ''
+ index_parse at OID: '1.3.6.1.4.1.1369.5.2.1.10.1.2.1' results: '1'
+ index_parse at OID: '1.3.6.1.4.1.1369.5.2.1.10.1.2.2' results: '2'
+ index_parse at OID: '1.3.6.1.4.1.1369.5.2.1.10.1.2.3' results: '3'
+ index_parse at OID: '1.3.6.1.4.1.1369.5.2.1.10.1.2.4' results: '4'
+ index_parse at OID: '1.3.6.1.4.1.1369.5.2.1.10.1.2.5' results: '5'
+ Located input field 'fwIfStatsIndex' [walk]
+ Executing SNMP walk for data @ '.1.3.6.1.4.1.1369.5.2.1.10.1.1'
+ Located input field 'fwIfName' [walk]
+ Executing SNMP walk for data @ '.1.3.6.1.4.1.1369.5.2.1.10.1.2'
+ Found item [fwIfName='eth0'] index: 1 [from value]
+ Found item [fwIfName='eth1'] index: 2 [from value]
+ Found item [fwIfName='eth2'] index: 3 [from value]
+ Found item [fwIfName='eth3'] index: 4 [from value]
+ Found item [fwIfName=''] index: 5 [from value]
+ Found data query XML file at '/usr/share/cacti/resource/snmp_queries/StoneSoft_fwIfTable.xml'
+ Found data query XML file at '/usr/share/cacti/resource/snmp_queries/StoneSoft_fwIfTable.xml'
+ Found data query XML file at '/usr/share/cacti/resource/snmp_queries/StoneSoft_fwIfTable.xml'
Btw, I don't understand : it works perfectly the first way (without regex) for other queries in other branches :

Code: Select all

<interface>
    <name>StoneSoft fwDiskSpaceUsageTable</name>
    <description>StoneGate disk space usage table stats</description>
    <oid_index>.1.3.6.1.4.1.1369.5.2.1.11.3.1.2</oid_index>
    <index_order>fwPartitionDevName</index_order>
    <index_order_type>numeric</index_order_type>
    <fields>
        <fwPartitionIndex>
            <name>Index</name>
            <method>walk</method>
            <source>value</source>
            <direction>input</direction>
            <oid>.1.3.6.1.4.1.1369.5.2.1.11.3.1.1</oid>
        </fwPartitionIndex>
        <fwPartitionDevName>
            <name>Device name</name>
            <method>walk</method>
            <source>value</source>
            <direction>input</direction>
            <oid>.1.3.6.1.4.1.1369.5.2.1.11.3.1.2</oid>
        </fwPartitionDevName>

Code: Select all

+ Running data query [46].
+ Found type = '3' [snmp query].
+ Found data query XML file at '/usr/share/cacti/resource/snmp_queries/StoneSoft_fwDiskSpaceUsageTable.xml'
+ XML file parsed ok.
+ Executing SNMP walk for list of indexes @ '.1.3.6.1.4.1.1369.5.2.1.11.3.1.2'
+ Index found at OID: '1.3.6.1.4.1.1369.5.2.1.11.3.1.2.1' value: '/dev/sda2'
+ Index found at OID: '1.3.6.1.4.1.1369.5.2.1.11.3.1.2.2' value: '/dev/sda6'
+ Index found at OID: '1.3.6.1.4.1.1369.5.2.1.11.3.1.2.3' value: '/dev/sda7'
+ Located input field 'fwPartitionIndex' [walk]
+ Executing SNMP walk for data @ '.1.3.6.1.4.1.1369.5.2.1.11.3.1.1'
+ Located input field 'fwPartitionDevName' [walk]
+ Executing SNMP walk for data @ '.1.3.6.1.4.1.1369.5.2.1.11.3.1.2'
+ Found item [fwPartitionDevName='/dev/sda2'] index: 1 [from value]
+ Found item [fwPartitionDevName='/dev/sda6'] index: 2 [from value]
+ Found item [fwPartitionDevName='/dev/sda7'] index: 3 [from value]
+ Located input field 'fwMountPointName' [walk]
+ Executing SNMP walk for data @ '.1.3.6.1.4.1.1369.5.2.1.11.3.1.3'
+ Found item [fwMountPointName='/'] index: 1 [from value]
+ Found item [fwMountPointName='/data'] index: 2 [from value]
+ Found item [fwMountPointName='/spool'] index: 3 [from value]
+ Found data query XML file at '/usr/share/cacti/resource/snmp_queries/StoneSoft_fwDiskSpaceUsageTable.xml'
+ Found data query XML file at '/usr/share/cacti/resource/snmp_queries/StoneSoft_fwDiskSpaceUsageTable.xml'
+ Found data query XML file at '/usr/share/cacti/resource/snmp_queries/StoneSoft_fwDiskSpaceUsageTable.xml'
+ Found data query XML file at '/usr/share/cacti/resource/snmp_queries/StoneSoft_fwDiskSpaceUsageTable.xml'
+ Found data query XML file at '/usr/share/cacti/resource/snmp_queries/StoneSoft_fwDiskSpaceUsageTable.xml'
+ Found data query XML file at '/usr/share/cacti/resource/snmp_queries/StoneSoft_fwDiskSpaceUsageTable.xml'
Cacti 0.8.8b + spine 0.8.8b
on Debian / Apache 2.2 / PHP 5.2 / MySQL 5.0
User avatar
Linegod
Developer
Posts: 1626
Joined: Thu Feb 20, 2003 10:16 am
Location: Canada
Contact:

Re: Indexed query issue

Post by Linegod »

In your other template, you are using <oid_index_parse>OID/REGEXP:.*\.([0-9]*)$</oid_index_parse>
--
Live fast, die young
You're sucking up my bandwidth.

J.P. Pasnak,CD
CCNA, LPIC-1
http://www.warpedsystems.sk.ca
User avatar
GLR
Cacti User
Posts: 55
Joined: Mon Jul 21, 2008 5:45 am
Location: Paris suburbs, France
Contact:

Re: Indexed query issue

Post by GLR »

Yes, this is the new option I've tested following your advice.
But the original one was the same syntax as in the 2nd query...
Cacti 0.8.8b + spine 0.8.8b
on Debian / Apache 2.2 / PHP 5.2 / MySQL 5.0
User avatar
GLR
Cacti User
Posts: 55
Joined: Mon Jul 21, 2008 5:45 am
Location: Paris suburbs, France
Contact:

Re: Indexed query issue

Post by GLR »

So no idea ?
Any SNMP indexed query expert ?
Cacti 0.8.8b + spine 0.8.8b
on Debian / Apache 2.2 / PHP 5.2 / MySQL 5.0
User avatar
GLR
Cacti User
Posts: 55
Joined: Mon Jul 21, 2008 5:45 am
Location: Paris suburbs, France
Contact:

Re: Indexed query issue

Post by GLR »

Here is the StoneGate 5.3 host template.
So, there is still an unresolved index problem with the firewall stats per interface. Any help would be greatly appreciated on this...

It includes :
- CPU usage details, global and per core
- Physical memory usage
- Current connections
- Allowed packets
- Discarded packets
- Rejected packets
- Logged packets
- Accounted packets
- Disk space usage per partition
- Standard interfaces traffic (including 64 bits counters support)
- Uptime
(Screenshots to be added)
Cacti 0.8.8b + spine 0.8.8b
on Debian / Apache 2.2 / PHP 5.2 / MySQL 5.0
noname
Cacti Guru User
Posts: 1566
Joined: Thu Aug 05, 2010 2:04 am
Location: Japan

Re: Indexed query issue

Post by noname »

GLR wrote:Yes, this is the new option I've tested following your advice.
But the original one was the same syntax as in the 2nd query...
It seems that your device doesn't return fwIfStatsIndex OIDs.. why?

Anyway, simply try as following for fwIfStatsIndex:

Code: Select all

<interface>
    <name>StoneSoft fwIfTable</name>
    <description>StoneGate firewall interface table stats</description>
    <oid_index>.1.3.6.1.4.1.1369.5.2.1.10.1.2</oid_index>
    <oid_index_parse>OID/REGEXP:.*\.([0-9]*)$</oid_index_parse>
    <index_order>fwIfName</index_order>
    <index_order_type>alphabetic</index_order_type>
    <fields>
        <fwIfStatsIndex>
            <name>Index</name>
            <source>index</source>
            <direction>input</direction>
        </fwIfStatsIndex>
        ...
"<source>index</source>" will use parsed index for it.

Simulated result:
XML file parsed ok.
Executing SNMP walk for list of indexes @ '.1.3.6.1.4.1.1369.5.2.1.10.1.2'
Index found at OID: '.1.3.6.1.4.1.1369.5.2.1.10.1.2.1' value: 'eth0'
Index found at OID: '.1.3.6.1.4.1.1369.5.2.1.10.1.2.2' value: 'eth1'
Index found at OID: '.1.3.6.1.4.1.1369.5.2.1.10.1.2.3' value: 'eth2'
Index found at OID: '.1.3.6.1.4.1.1369.5.2.1.10.1.2.4' value: 'eth3'
Index found at OID: '.1.3.6.1.4.1.1369.5.2.1.10.1.2.5' value: ''
index_parse at OID: '.1.3.6.1.4.1.1369.5.2.1.10.1.2.1' results: '1'
index_parse at OID: '.1.3.6.1.4.1.1369.5.2.1.10.1.2.2' results: '2'
index_parse at OID: '.1.3.6.1.4.1.1369.5.2.1.10.1.2.3' results: '3'
index_parse at OID: '.1.3.6.1.4.1.1369.5.2.1.10.1.2.4' results: '4'
index_parse at OID: '.1.3.6.1.4.1.1369.5.2.1.10.1.2.5' results: '5'
Inserting index data for field 'fwIfStatsIndex' [value='1']
Inserting index data for field 'fwIfStatsIndex' [value='2']
Inserting index data for field 'fwIfStatsIndex' [value='3']
Inserting index data for field 'fwIfStatsIndex' [value='4']
Inserting index data for field 'fwIfStatsIndex' [value='5']

Located input field 'fwIfName' [walk]
Executing SNMP walk for data @ '.1.3.6.1.4.1.1369.5.2.1.10.1.2'
Found item [fwIfName='eth0'] index: 1 [from value]
Found item [fwIfName='eth1'] index: 2 [from value]
Found item [fwIfName='eth2'] index: 3 [from value]
Found item [fwIfName='eth3'] index: 4 [from value]
Found item [fwIfName=''] index: 5 [from value]
...
User avatar
GLR
Cacti User
Posts: 55
Joined: Mon Jul 21, 2008 5:45 am
Location: Paris suburbs, France
Contact:

Re: Indexed query issue

Post by GLR »

Hello,

... And thank you for your help !

Yes, I now get this output :

Code: Select all

+ Running data query [44].
+ Found type = '3' [snmp query].
+ Found data query XML file at '/usr/share/cacti/resource/snmp_queries/StoneSoft_fwIfTable.xml'
+ XML file parsed ok.
+ Executing SNMP walk for list of indexes @ '.1.3.6.1.4.1.1369.5.2.1.10.1.2'
+ Index found at OID: '1.3.6.1.4.1.1369.5.2.1.10.1.2.1' value: 'eth0_0'
+ Index found at OID: '1.3.6.1.4.1.1369.5.2.1.10.1.2.2' value: 'eth0_1'
+ Index found at OID: '1.3.6.1.4.1.1369.5.2.1.10.1.2.3' value: 'eth0_2'
+ Index found at OID: '1.3.6.1.4.1.1369.5.2.1.10.1.2.4' value: 'eth0_3'
+ Index found at OID: '1.3.6.1.4.1.1369.5.2.1.10.1.2.5' value: 'eth0_4'
+ Index found at OID: '1.3.6.1.4.1.1369.5.2.1.10.1.2.6' value: ''
+ index_parse at OID: '1.3.6.1.4.1.1369.5.2.1.10.1.2.1' results: '1'
+ index_parse at OID: '1.3.6.1.4.1.1369.5.2.1.10.1.2.2' results: '2'
+ index_parse at OID: '1.3.6.1.4.1.1369.5.2.1.10.1.2.3' results: '3'
+ index_parse at OID: '1.3.6.1.4.1.1369.5.2.1.10.1.2.4' results: '4'
+ index_parse at OID: '1.3.6.1.4.1.1369.5.2.1.10.1.2.5' results: '5'
+ index_parse at OID: '1.3.6.1.4.1.1369.5.2.1.10.1.2.6' results: '6'
+ Inserting index data for field 'fwIfStatsIndex' [value='1']
+ Inserting index data for field 'fwIfStatsIndex' [value='2']
+ Inserting index data for field 'fwIfStatsIndex' [value='3']
+ Inserting index data for field 'fwIfStatsIndex' [value='4']
+ Inserting index data for field 'fwIfStatsIndex' [value='5']
+ Inserting index data for field 'fwIfStatsIndex' [value='6']
+ Located input field 'fwIfName' [walk]
+ Executing SNMP walk for data @ '.1.3.6.1.4.1.1369.5.2.1.10.1.2'
+ Found item [fwIfName='eth0_0'] index: 1 [from value]
+ Found item [fwIfName='eth0_1'] index: 2 [from value]
+ Found item [fwIfName='eth0_2'] index: 3 [from value]
+ Found item [fwIfName='eth0_3'] index: 4 [from value]
+ Found item [fwIfName='eth0_4'] index: 5 [from value]
+ Found item [fwIfName=''] index: 6 [from value]
+ Found data query XML file at '/usr/share/cacti/resource/snmp_queries/StoneSoft_fwIfTable.xml'
+ Found data query XML file at '/usr/share/cacti/resource/snmp_queries/StoneSoft_fwIfTable.xml'
+ Found data query XML file at '/usr/share/cacti/resource/snmp_queries/StoneSoft_fwIfTable.xml'
But I still encounter the same issue in the datasources :

Image

Regarding the fact we don't get anything on fwIfStatsIndex OIDs, I got the following reply from the support :
R&D tells that OID 1369.5.2.1.10.1.1 is fwIfStatsIndex, which is in our MIB described as not-accessible - as a 1369.5.2.1.10.1's sequence index, there's no need to access that.
Cacti 0.8.8b + spine 0.8.8b
on Debian / Apache 2.2 / PHP 5.2 / MySQL 5.0
noname
Cacti Guru User
Posts: 1566
Joined: Thu Aug 05, 2010 2:04 am
Location: Japan

Re: Indexed query issue

Post by noname »

In your "Indexed query definition", please make sure whether all datasources are selected properly (and enabled checkbox).
(If you modified data query or data template, then re-create all graphs and datasources.)
R&D tells that OID 1369.5.2.1.10.1.1 is fwIfStatsIndex, which is in our MIB described as not-accessible - as a 1369.5.2.1.10.1's sequence index, there's no need to access that.
Weird.. :(
User avatar
GLR
Cacti User
Posts: 55
Joined: Mon Jul 21, 2008 5:45 am
Location: Paris suburbs, France
Contact:

Re: Indexed query issue

Post by GLR »

You are indeed right, as I defined all entries in the data template...
So I've updated the index query definition :

Image

... But the data sources still remain wrong : :(

Image
Cacti 0.8.8b + spine 0.8.8b
on Debian / Apache 2.2 / PHP 5.2 / MySQL 5.0
noname
Cacti Guru User
Posts: 1566
Joined: Thu Aug 05, 2010 2:04 am
Location: Japan

Re: Indexed query issue

Post by noname »

Mmm, then try this for <fwIfStatsIndex> field on trial...

Change from

Code: Select all

        <fwIfStatsIndex>
            <name>Index</name>
            <source>index</source>
            <direction>input</direction>
        </fwIfStatsIndex>
to

Code: Select all

        <fwIfStatsIndex>
            <name>Index</name>
            <method>walk</method>
            <source>OID/REGEXP:.*\.([0-9]*)$</source>
            <direction>input</direction>
            <oid>.1.3.6.1.4.1.1369.5.2.1.10.1.2</oid>
        </fwIfStatsIndex>
If it worked, I can't understand why can't re-use index value for <source>..
User avatar
GLR
Cacti User
Posts: 55
Joined: Mon Jul 21, 2008 5:45 am
Location: Paris suburbs, France
Contact:

Re: Indexed query issue

Post by GLR »

Now I get :

Code: Select all

+ Running data query [44].
+ Found type = '3' [snmp query].
+ Found data query XML file at '/usr/share/cacti/resource/snmp_queries/StoneSoft_fwIfTable.xml'
+ XML file parsed ok.
+ Executing SNMP walk for list of indexes @ '.1.3.6.1.4.1.1369.5.2.1.10.1.2'
+ Index found at OID: '1.3.6.1.4.1.1369.5.2.1.10.1.2.1' value: 'eth0_0'
+ Index found at OID: '1.3.6.1.4.1.1369.5.2.1.10.1.2.2' value: 'eth0_1'
+ Index found at OID: '1.3.6.1.4.1.1369.5.2.1.10.1.2.3' value: 'eth0_2'
+ Index found at OID: '1.3.6.1.4.1.1369.5.2.1.10.1.2.4' value: 'eth0_3'
+ Index found at OID: '1.3.6.1.4.1.1369.5.2.1.10.1.2.5' value: 'eth0_4'
+ Index found at OID: '1.3.6.1.4.1.1369.5.2.1.10.1.2.6' value: ''
+ index_parse at OID: '1.3.6.1.4.1.1369.5.2.1.10.1.2.1' results: '1'
+ index_parse at OID: '1.3.6.1.4.1.1369.5.2.1.10.1.2.2' results: '2'
+ index_parse at OID: '1.3.6.1.4.1.1369.5.2.1.10.1.2.3' results: '3'
+ index_parse at OID: '1.3.6.1.4.1.1369.5.2.1.10.1.2.4' results: '4'
+ index_parse at OID: '1.3.6.1.4.1.1369.5.2.1.10.1.2.5' results: '5'
+ index_parse at OID: '1.3.6.1.4.1.1369.5.2.1.10.1.2.6' results: '6'
+ Located input field 'fwIfStatsIndex' [walk]
+ Executing SNMP walk for data @ '.1.3.6.1.4.1.1369.5.2.1.10.1.2'
+ Found item [fwIfStatsIndex='1'] index: 1 [from regexp oid parse]
+ Found item [fwIfStatsIndex='2'] index: 2 [from regexp oid parse]
+ Found item [fwIfStatsIndex='3'] index: 3 [from regexp oid parse]
+ Found item [fwIfStatsIndex='4'] index: 4 [from regexp oid parse]
+ Found item [fwIfStatsIndex='5'] index: 5 [from regexp oid parse]
+ Found item [fwIfStatsIndex='6'] index: 6 [from regexp oid parse]
+ Located input field 'fwIfName' [walk]
+ Executing SNMP walk for data @ '.1.3.6.1.4.1.1369.5.2.1.10.1.2'
+ Found item [fwIfName='eth0_0'] index: 1 [from value]
+ Found item [fwIfName='eth0_1'] index: 2 [from value]
+ Found item [fwIfName='eth0_2'] index: 3 [from value]
+ Found item [fwIfName='eth0_3'] index: 4 [from value]
+ Found item [fwIfName='eth0_4'] index: 5 [from value]
+ Found item [fwIfName=''] index: 6 [from value]
+ Found data query XML file at '/usr/share/cacti/resource/snmp_queries/StoneSoft_fwIfTable.xml'
+ Found data query XML file at '/usr/share/cacti/resource/snmp_queries/StoneSoft_fwIfTable.xml'
+ Found data query XML file at '/usr/share/cacti/resource/snmp_queries/StoneSoft_fwIfTable.xml'
But this kind of data source, still not good but with a RRA file name :

Image
Cacti 0.8.8b + spine 0.8.8b
on Debian / Apache 2.2 / PHP 5.2 / MySQL 5.0
noname
Cacti Guru User
Posts: 1566
Joined: Thu Aug 05, 2010 2:04 am
Location: Japan

Re: Indexed query issue

Post by noname »

Mmmmm, then try this...

From

Code: Select all

    <index_order>fwIfName</index_order>
    <index_order_type>alphabetic</index_order_type>
to

Code: Select all

    <index_order>fwIfStatsIndex</index_order>
    <index_order_type>numeric</index_order_type>
Because normally Cacti expects that index won't have null-value,
so probably fwIfName is unsuited to index. (I think)
User avatar
GLR
Cacti User
Posts: 55
Joined: Mon Jul 21, 2008 5:45 am
Location: Paris suburbs, France
Contact:

Re: Indexed query issue

Post by GLR »

Hello !

This way, it seems to work !
I will confirm later and provide screenshots, but it seems to be a success. Thanks so much !!!

Code: Select all

<interface>
    <name>StoneSoft fwIfTable</name>
    <description>StoneGate firewall interface table stats</description>
    <oid_index>.1.3.6.1.4.1.1369.5.2.1.10.1.2</oid_index>
    <oid_index_parse>OID/REGEXP:.*\.([0-9]*)$</oid_index_parse>
    <index_order>fwIfStatsIndex</index_order>
    <index_order_type>numeric</index_order_type>
    <fields>
        <fwIfStatsIndex>
            <name>Index</name>
            <method>walk</method>
            <source>OID/REGEXP:.*\.([0-9]*)$</source>
            <direction>input</direction>
            <oid>.1.3.6.1.4.1.1369.5.2.1.10.1.2</oid>
        </fwIfStatsIndex>
May be this last one was one of the main changes to be applied.
Do you want to test again one of the previous syntax for <fwIfStatsIndex> ?
Cacti 0.8.8b + spine 0.8.8b
on Debian / Apache 2.2 / PHP 5.2 / MySQL 5.0
Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests