and post Verbose Query (you can copy & paste it as text).<oid_index>.1.3.6.1.4.1.3375.2.1.2.12.1.2.1.1</oid_index>
<oid_index_parse>OID/REGEXP:^.{35}(.*)</oid_index_parse>
<index_order_type>alphabetic</index_order_type>
Data Template → Get SNMP Data (indexed) → Index Value/Type?
Moderators: Developers, Moderators
Re: Data Template → Get SNMP Data (indexed) → Index Value/Ty
Hmm, then use these settings
Re: Data Template → Get SNMP Data (indexed) → Index Value/Ty
Here is the requested Verbose Query:noname wrote:Hmm, then use these settingsand post Verbose Query (you can copy & paste it as text).<oid_index>.1.3.6.1.4.1.3375.2.1.2.12.1.2.1.1</oid_index>
<oid_index_parse>OID/REGEXP:^.{35}(.*)</oid_index_parse>
<index_order_type>alphabetic</index_order_type>
Code: Select all
+ Running data query [33].
+ Found type = '3' [snmp query].
+ Found data query XML file at '/usr/share/cacti_cvs/resource/snmp_queries/f5_trunk_interfaces.xml'
+ XML file parsed ok.
+ Executing SNMP walk for list of indexes @ '.1.3.6.1.4.1.3375.2.1.2.12.1.2.1.1'
+ Index found at OID: '.1.3.6.1.4.1.3375.2.1.2.12.1.2.1.1.6.109.97.115.116.101.114' value: 'master'
+ index_parse at OID: '.1.3.6.1.4.1.3375.2.1.2.12.1.2.1.1.6.109.97.115.116.101.114' results: '.6.109.97.115.116.101.114'
+ Inserting index data for field 'Index' [value='.6.109.97.115.116.101.114']
+ Located input field 'TrunkName' [walk]
+ Executing SNMP walk for data @ '.1.3.6.1.4.1.3375.2.1.2.12.1.2.1.1'
+ Found item [TrunkName='master'] index: .6.109.97.115.116.101.114 [from value]
+ Found data query XML file at '/usr/share/cacti_cvs/resource/snmp_queries/f5_trunk_interfaces.xml'
+ Found data query XML file at '/usr/share/cacti_cvs/resource/snmp_queries/f5_trunk_interfaces.xml'
+ Found data query XML file at '/usr/share/cacti_cvs/resource/snmp_queries/f5_trunk_interfaces.xml'
Re: Data Template → Get SNMP Data (indexed) → Index Value/Ty
It seemed skipping characters ".{35}" didn't work as expected..
Then try this:
Then try this:
Code: Select all
<oid_index_parse>OID/REGEXP:^\.1\.3\.6\.1\.4\.1\.3375\.2\.1\.2\.12\.1\.2\.1\.1\.(.*)</oid_index_parse>
Re: Data Template → Get SNMP Data (indexed) → Index Value/Ty
This produced the exact same results as the previous <oid_index_parse/>.noname wrote:It seemed skipping characters ".{35}" didn't work as expected..
Then try this:Code: Select all
<oid_index_parse>OID/REGEXP:^\.1\.3\.6\.1\.4\.1\.3375\.2\.1\.2\.12\.1\.2\.1\.1\.(.*)</oid_index_parse>
Re: Data Template → Get SNMP Data (indexed) → Index Value/Ty
Okay, this is the last challenge..
(A) Using <source>OID/REGEXP:...</source> for index
(B) Using TrunkName as index
If it didn't work either of them, I ran out of idea.. sorry.
(A) Using <source>OID/REGEXP:...</source> for index
Code: Select all
<query>
<name>F5 Trunk Bandwidth Information</name>
<description>Queries a F5 for information related to a trunk's bandwidth</description>
<oid_index>.1.3.6.1.4.1.3375.2.1.2.12.1.2.1.1</oid_index>
<oid_index_parse>OID/REGEXP:^\.1\.3\.6\.1\.4\.1\.3375\.2\.1\.2\.12\.1\.2\.1\.1\.(.*)</oid_index_parse>
<index_order>Index</index_order>
<index_order_type>alphabetic</index_order_type>
<index_title_format>|chosen_order_field|</index_title_format>
<fields>
<Index>
<name>Index</name>
<method>walk</method>
<source>OID/REGEXP:^\.1\.3\.6\.1\.4\.1\.3375\.2\.1\.2\.12\.1\.2\.1\.1\.(.*)</source>
<direction>input</direction>
<oid>.1.3.6.1.4.1.3375.2.1.2.12.1.2.1.1</oid>
</Index>
<TrunkName>
<name>Trunk Name</name>
<method>walk</method>
<source>value</source>
<direction>input</direction>
<oid>.1.3.6.1.4.1.3375.2.1.2.12.1.2.1.1</oid>
</TrunkName>
<TrunkOperBw>
<name>Trunk Bandwidth</name>
<method>walk</method>
<source>value</source>
<direction>output</direction>
<oid>.1.3.6.1.4.1.3375.2.1.2.12.1.2.1.5</oid>
</TrunkOperBw>
</fields>
</query>
Code: Select all
<query>
<name>F5 Trunk Bandwidth Information</name>
<description>Queries a F5 for information related to a trunk's bandwidth</description>
<oid_index>.1.3.6.1.4.1.3375.2.1.2.12.1.2.1.1</oid_index>
<oid_index_parse>OID/REGEXP:^\.1\.3\.6\.1\.4\.1\.3375\.2\.1\.2\.12\.1\.2\.1\.1\.(.*)</oid_index_parse>
<index_order>TrunkName</index_order>
<index_order_type>alphabetic</index_order_type>
<index_title_format>|chosen_order_field|</index_title_format>
<fields>
<TrunkName>
<name>Trunk Name</name>
<method>walk</method>
<source>value</source>
<direction>input</direction>
<oid>.1.3.6.1.4.1.3375.2.1.2.12.1.2.1.1</oid>
</TrunkName>
<TrunkOperBw>
<name>Trunk Bandwidth</name>
<method>walk</method>
<source>value</source>
<direction>output</direction>
<oid>.1.3.6.1.4.1.3375.2.1.2.12.1.2.1.5</oid>
</TrunkOperBw>
</fields>
</query>
- TheWitness
- Developer
- Posts: 17047
- Joined: Tue May 14, 2002 5:08 pm
- Location: MI, USA
- Contact:
Re: Data Template → Get SNMP Data (indexed) → Index Value/Ty
These advanced Data Query concepts cause issues as Template Developers come up to speed. Over time, you brain will figure this out for you. Personally Regular Expressions still read like Chinese to me (no offense to the Chinese), and I've been programming for over 30 years.
TheWitness
TheWitness
True understanding begins only when we realize how little we truly understand...
Life is an adventure, let yours begin with Cacti!
Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages
For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
Life is an adventure, let yours begin with Cacti!
Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages
For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
Re: Data Template → Get SNMP Data (indexed) → Index Value/Ty
Thanks for your help noname, but neither of those suggestions worked either. I redid all of the templates just in case I had made a mistake, but even then I'm running into this issue with the new templates.
Re: Data Template → Get SNMP Data (indexed) → Index Value/Ty
So I changed how I was implementing the graphs. Previously I was attempting to create the graphs after assigning them to the Associated Graph Templates. Instead, on the "Create Graphs for this Host" page I attempted to create the graphs directly from the Data Query section. This allowed for the graphs to be created (kinda... the graphs were "Created" but the RRD files were not created) without prompting me for the Output Type ID, Index Value, and Index Type. Now I just need to figure out why the graphs didn't have an RRD file created for them.
Re: Data Template → Get SNMP Data (indexed) → Index Value/Ty
FYI to anyone having this issue...
Ultimately, I wasn't able to get this to work. As a work-around I wrote a PHP script that would query the OID values I needed from the F5 unit and parse the results and output what I needed. After I had that script, I re-worked the templates to just use that outputted data.
Ultimately, I wasn't able to get this to work. As a work-around I wrote a PHP script that would query the OID values I needed from the F5 unit and parse the results and output what I needed. After I had that script, I re-worked the templates to just use that outputted data.
Who is online
Users browsing this forum: No registered users and 3 guests