Cisco interface operational status monitor

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

Moderators: Moderators, Developers

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

#46 Post by gandalf » Sat Aug 18, 2007 3:52 am

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

#47 Post by djoki » Mon Aug 20, 2007 8:49 am

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

#48 Post by maxxic » Wed Aug 22, 2007 5:17 am

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
[[email protected] 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
pic1.JPG
I don't see graf of status interface
pic1.JPG (15.51 KiB) Viewed 24516 times
pic2.JPG
I click on graf and I SEE it!
pic2.JPG (25.9 KiB) Viewed 24518 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

#49 Post by djoki » Wed Aug 22, 2007 11:25 am

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

#50 Post by djoki » Wed Aug 22, 2007 12:06 pm

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:

#51 Post by maxxic » Thu Aug 23, 2007 1:06 am

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
pic3.JPG
Something like that!
pic3.JPG (68.02 KiB) Viewed 24445 times

User avatar
maxxic
Posts: 9
Joined: Wed Aug 22, 2007 4:52 am
Location: Russia
Contact:

Improvement

#52 Post by maxxic » Thu Aug 23, 2007 2:03 am

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
fig3.JPG
Result
fig3.JPG (25.27 KiB) Viewed 24436 times
fig2.JPG
Changes in Graph Template
fig2.JPG (67.47 KiB) Viewed 24436 times
fig1.JPG
Make function
fig1.JPG (58.94 KiB) Viewed 24436 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

#53 Post by djoki » Thu Aug 23, 2007 9:36 am

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: 22375
Joined: Thu Dec 02, 2004 2:46 am
Location: Muenster, Germany
Contact:

#54 Post by gandalf » Thu Aug 23, 2007 2:32 pm

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

#55 Post by djoki » Thu Aug 23, 2007 2:47 pm

Yes I have this option ...

User avatar
maxxic
Posts: 9
Joined: Wed Aug 22, 2007 4:52 am
Location: Russia
Contact:

#56 Post by maxxic » Fri Aug 24, 2007 12:30 am

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

#57 Post by djoki » Fri Aug 24, 2007 7:40 am

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: 22375
Joined: Thu Dec 02, 2004 2:46 am
Location: Muenster, Germany
Contact:

#58 Post by gandalf » Fri Aug 24, 2007 8:58 am

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

#59 Post by djoki » Fri Aug 24, 2007 10:38 am

I use cactid 0.8.6i.

you have a zip or tar.gr archive ?

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

#60 Post by gandalf » Fri Aug 24, 2007 2:17 pm

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

Post Reply