Cisco interface operational status monitor

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

Moderators: Developers, Moderators

Post Reply
User avatar
gandalf
Developer
Posts: 22383
Joined: Thu Dec 02, 2004 2:46 am
Location: Muenster, Germany
Contact:

Post by gandalf »

No, you will want to import this xml file. It holds the Template definitions required for cacti
Reinhard
djoki
Posts: 26
Joined: Wed Aug 15, 2007 4:13 pm

Post by djoki »

ok,

I've importthe 3 files.

must I fill these fields?
If so, can you explain me that I must put?

Image

If i create, i have poller errors:

Code: Select all

CMDPHP: Poller[0] ERROR: SQL Assoc Failed "select snmp_query_graph_rrd.snmp_field_name, data_template_rrd.id as data_template_rrd_id from (snmp_query_graph_rrd,data_template_rrd) where snmp_query_graph_rrd.data_template_rrd_id=data_template_rrd.local_data_template_rrd_id and snmp_query_graph_rrd.snmp_query_graph_id= and snmp_query_graph_rrd.data_template_id=192 and data_template_rrd.local_data_id=1017" 
can you help me ?
User avatar
maxxic
Posts: 9
Joined: Wed Aug 22, 2007 4:52 am
Location: Russia
Contact:

One more strange trouble

Post by maxxic »

I have FedoreCore 6, cacti-0.8.6j

I do:
1. Import Template from Local File cacti_data_query_snmp_interface_statistics_730.xml, cacti_data_template_interface_status_190.xml, cacti_graph_template_interface_status_679.xml

2. Make changes in file interface.xml
[root@tepulifc60bnk99 snmp_queries]# cat interface.xml
......................
<ifOperStatus>
<name>Status</name>
<method>walk</method>
<source>VALUE/REGEXP:[a-zA-Z]{1,}\(([1-]{1})+\)$</source>
<direction>output</direction>
<oid>.1.3.6.1.2.1.2.2.1.8</oid>
</ifOperStatus>
......................

3. Make changes as said yeled in /var/www/html/cacti/lib/snmp.php
define("REGEXP_SNMP_TRIM", "(hex|counter(32|64)|gauge|gauge(32|64)|float|ipaddress|string|integer):|(up|down)\(|\)$");

Results:
1. No error mesages
2. I don't see graph of status interface
3. But if I click in place where graf is must be - I SEE it!

Why I can't see the status of interface in tree view mode?

Pleease, help! :'-(
Attachments
I don't see graf of status interface
I don't see graf of status interface
pic1.JPG (15.51 KiB) Viewed 27524 times
I click on graf and I SEE it!
I click on graf and I SEE it!
pic2.JPG (25.9 KiB) Viewed 27526 times
Last edited by maxxic on Thu Aug 23, 2007 1:08 am, edited 1 time in total.
djoki
Posts: 26
Joined: Wed Aug 15, 2007 4:13 pm

Post by djoki »

Hello

I think that my probleme what that i'ven't ifOperStatus(Status) option in Data Queries

Image

plz help :-?
djoki
Posts: 26
Joined: Wed Aug 15, 2007 4:13 pm

Post by djoki »

it's ok , in my inerface.xml i have forgot to change input => output.

But no graph ... and a SQL error :

Code: Select all

08/22/2007 01:07:11 PM - CMDPHP: Poller[0] ERROR: SQL Assoc Failed "select snmp_query_graph_rrd.snmp_field_name, data_template_rrd.id as data_template_rrd_id from (snmp_query_graph_rrd,data_template_rrd) where snmp_query_graph_rrd.data_template_rrd_id=data_template_rrd.local_data_template_rrd_id and snmp_query_graph_rrd.snmp_query_graph_id= and snmp_query_graph_rrd.data_template_id=192 and data_template_rrd.local_data_id=1389" 
User avatar
maxxic
Posts: 9
Joined: Wed Aug 22, 2007 4:52 am
Location: Russia
Contact:

Post by maxxic »

Hi!
djoki, check next Data Sources -> "yourdevice" - Status - "yourinterfece" in section Custom Data: Index Type must ifDescr, Index Value must "yourinterfece" and Output Type ID must Interface Operational status.

P.S. Can anybody help me (see my post before)?!
Attachments
Something like that!
Something like that!
pic3.JPG (68.02 KiB) Viewed 27453 times
User avatar
maxxic
Posts: 9
Joined: Wed Aug 22, 2007 4:52 am
Location: Russia
Contact:

Improvement

Post by maxxic »

I think I made a little improvemet of good and impotant flipflap's idea.
It's not comfortably to see graph the down interface is biger than up interface and I propose use CDEFs to make graph then up interface will be looks as high graph and down interface will be looks as no graph.
It's easy to make :
1. Graph Management -> CDEFs -> Add. Name your function. I called Decris&invert.
2. Add Item #1 Special Data Source: CURRENT_DATA_SOURCE
Add Item #2 Custom String: 2
Add Item #3 Operator: -
Add Item #4 Custom String: -1
Add Item #5 Operator: *
3. Graph Templates -> Interface - Status -> Item # 1 and select CDEF Function, in my case Decris&invert. Correct Item #3 field Text Format (1 = Up | 0 = Down)

That's All!

P.S. But my problem not over! :'-( - I still not see graph in "preview" mode. Plz HELP!
P.P.S. Sorry for gramma. :o
Attachments
Result
Result
fig3.JPG (25.27 KiB) Viewed 27444 times
Changes in Graph Template
Changes in Graph Template
fig2.JPG (67.47 KiB) Viewed 27444 times
Make function
Make function
fig1.JPG (58.94 KiB) Viewed 27444 times
Last edited by maxxic on Fri Aug 24, 2007 12:17 am, edited 1 time in total.
djoki
Posts: 26
Joined: Wed Aug 15, 2007 4:13 pm

Post by djoki »

hello

thanks for your help maxxic :)

but, i have an other probem. :-?

It work good with cmd.php but not with cactid.
:x
With cactid i have this error :

Code: Select all

08/23/2007 10:32:06 AM - CACTID: Poller[0] Host[12] DS[1665] WARNING: Result from SNMP not valid. Partial Result: ...  
08/23/2007 10:32:06 AM - CACTID: Poller[0] Host[12] DS[1664] SNMP: v2: 10.0.0.1, dsname: int_status, oid: .1.3.6.1.2.1.2.2.1.8.2, value: U  
User avatar
gandalf
Developer
Posts: 22383
Joined: Thu Dec 02, 2004 2:46 am
Location: Muenster, Germany
Contact:

Post by gandalf »

Please verify snmpd.conf option

Code: Select all

dontPrintUnits true
as given at http://docs.cacti.net/node/414
Reinhard
djoki
Posts: 26
Joined: Wed Aug 15, 2007 4:13 pm

Post by djoki »

Yes I have this option ...
User avatar
maxxic
Posts: 9
Joined: Wed Aug 22, 2007 4:52 am
Location: Russia
Contact:

Post by maxxic »

gandalf wrote:Please verify snmpd.conf option

Code: Select all

dontPrintUnits true
as given at http://docs.cacti.net/node/414
Reinhard
Wow!.. Why is here snmpd.conf?!.
When I and djoki take interface status from the cisco router/switch. Cisco device don't have snmpd.conf ;-)
Sapienti sat
djoki
Posts: 26
Joined: Wed Aug 15, 2007 4:13 pm

Post by djoki »

maxxic wrote:
gandalf wrote:Please verify snmpd.conf option

Code: Select all

dontPrintUnits true
as given at http://docs.cacti.net/node/414
Reinhard
Wow!.. Why is here snmpd.conf?!.
When I and djoki take interface status from the cisco router/switch. Cisco device don't have snmpd.conf ;-)
yes it's true ...
And ... I think that is not that cause problem.
It work fine with cmd.php but not with cactid <= that the problem

When I have test with cmc.php i've the good values. But i'can't use cmc.php at work ... it's to long to process.
User avatar
gandalf
Developer
Posts: 22383
Joined: Thu Dec 02, 2004 2:46 am
Location: Muenster, Germany
Contact:

Post by gandalf »

You're correct about the Cisco conf. It was meant as a test because I suspect, that cactid polls the OIDs without suppressing UNITs while cmd.php suppresses them; that's all.
In this case, please download latest cactid from SVN, compile and retry. Run it manually from cli against one erraneous host using --verbosity=5 and post output
Reinhard
djoki
Posts: 26
Joined: Wed Aug 15, 2007 4:13 pm

Post by djoki »

I use cactid 0.8.6i.

you have a zip or tar.gr archive ?
User avatar
gandalf
Developer
Posts: 22383
Joined: Thu Dec 02, 2004 2:46 am
Location: Muenster, Germany
Contact:

Post by gandalf »

No, it's SVN. Find it at http://www.cacti.net/cactid_download.php
Reinhard
Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests