Juniper FRU statistics

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

Moderators: Developers, Moderators

Post Reply
bradley
Posts: 38
Joined: Fri Dec 02, 2005 7:02 am
Location: United Kingdom
Contact:

Juniper FRU statistics

Post by bradley »

Hi all,

We use Juniper M160's and Juniper M10's and I've created the following data query
which can pull off CPU, Buffer & Heap, and temperature from the Field Replacable Units
within each router.

Copy the data query into resource/snmp_queries and then import the host template
which is also attached.

I hope you find them useful.

--
Bradley Kite
Attachments
cacti_host_template_juniper_m_series.xml
Host Template for Juniper M10 and M160 (and maybe other M Series routers too)
(136.38 KiB) Downloaded 6609 times
cacti_data_query_juniper_fru_stats.xml
Juniper FRU Statistics Data Query
(34.15 KiB) Downloaded 5042 times
User avatar
bleearg
Cacti User
Posts: 55
Joined: Wed Apr 27, 2005 9:37 am

Post by bleearg »

These are some great templates, however, when attempting to do the query, it appears that the snmpwalk process starts at the beginning of the MIB tree and queries for every single OID on the system. In addition, when going to "Create graphs for this host", the following shows up under the Graph Templates section:

Warning: reset(): Passed variable is not an array or object in /opt/web/virtual/cacti/graphs_new.php on line 534

Warning: Variable passed to each() is not an array or object in /opt/web/virtual/cacti/graphs_new.php on line 535

Warning: reset(): Passed variable is not an array or object in /opt/web/virtual/cacti/graphs_new.php on line 610

Warning: Variable passed to each() is not an array or object in /opt/web/virtual/cacti/graphs_new.php on line 611

EDIT: After looking at the data query, there are no OIDs in it. Reading through the Cacti docs, I found this glaring out at me: "All data queries have two parts, the XML file and the definition within Cacti. An XML file must be created for each query, that defines where each piece of information is and how to retrieve it. This could be thought of as the actual query. The second part is a definition within Cacti, which tells Cacti where to find the XML file and associates the data query with one or more graph templates."

Can you post your actual XML file?
mgeni
Cacti User
Posts: 65
Joined: Fri Mar 25, 2005 8:12 am

Post by mgeni »

I am seeing similar issues. It would be nice if you could post your XML file.
bradley
Posts: 38
Joined: Fri Dec 02, 2005 7:02 am
Location: United Kingdom
Contact:

Data Query XML File

Post by bradley »

Hi all,

Sorry for the delay, indeed I did forget the XML file. It is now attached.

Regards
--
Brad.
Attachments
juniper_fru.xml
Place this XML file in resources/snmp_queries
(2.14 KiB) Downloaded 4159 times
waas
Posts: 2
Joined: Wed Jan 25, 2006 5:03 am

Post by waas »

Hi all

I've tried to import these xml files (in the correct order) but don't work:

First of all i put the 2 query files in /resource/snmp_queries and import from it. All ok, but ony one of these runs. But when i try to import the host template (just making a copy&paste) nothing else mathers and no new Host type seems to apear here.

Anybody have the same error?

waas

P.D: ... Juniper M20 witch PIC integrated services and 2 Ge, 1 STM16 and 4 STM4. I neeed to monitor it!!
User avatar
bleearg
Cacti User
Posts: 55
Joined: Wed Apr 27, 2005 9:37 am

Post by bleearg »

You have to put the juniper_fru.xml query on the server itself under <cacti_dir>/resources/snmp_queries/. You can't import this file via the Import tool.
mgob
Posts: 25
Joined: Wed Dec 07, 2005 3:43 am
Location: Arizona
Contact:

Post by mgob »

no joy on a m20 :(
mgeni
Cacti User
Posts: 65
Joined: Fri Mar 25, 2005 8:12 am

Post by mgeni »

I am still having no luck graphing well on M10i.
waas
Posts: 2
Joined: Wed Jan 25, 2006 5:03 am

Post by waas »

You have to put the juniper_fru.xml query on the server itself under <cacti_dir>/resources/snmp_queries/. You can't import this file via the Import tool.
Ok. I've put the two queries (juniper_fru.xml and cacti_data_query_juniper_fru_stats.xml) under <cacti_dir>/resources/snmp_queries. Later I've tried to import the host template from the web interface and the message is "Error: XML: Hash version does not exist." If i try to import one of the data queries from the web interface it seems all ok, but no graphs templates appear and no snmp queris are done...
no joy on a m20
:evil: :evil:
User avatar
bleearg
Cacti User
Posts: 55
Joined: Wed Apr 27, 2005 9:37 am

Post by bleearg »

These are the steps I took:

1. Import the cacti_host_template_juniper_m_series.xml and the cacti_data_query_juniper_fru_stats.xml via the web interface Import function.
2. Put the juniper_fru.xml in the <cacti_dir>/resources/snmp_queries/ directory.
3. Add a new device that is an M-Series router (M5, M7i, M20, M40, etc.).

Again, even after all that, the graphs don't seem to be working. The queries run as expected, but only one data point is entered on the graph - the rest of the graph is blank. I can probably troubleshoot it myself, but I just haven't had the time...maybe this weekend.
mru
Posts: 1
Joined: Mon Jan 30, 2006 5:56 am

Juniper FRU statistics

Post by mru »

Hi all
bleearg wrote:Again, even after all that, the graphs don't seem to be working. The queries run as expected, but only one data point is entered on the graph - the rest of the graph is blank.
I had the same problem here and discovered two options to solve it.
1. Change the polling-interval to 1 min.
2. Modify the the "Juniper - FRU*" "Data Templates" and change in "Data Source" the "Step" value to 300 and in "Data Source Item" the "Hearthbeat" value to 600. After that recreate the corresponding rrd files.
petero
Posts: 13
Joined: Sun Jul 17, 2005 3:45 pm
Location: Poland

Problems with creating rrd and graphs

Post by petero »

Hi i put the FRU snmp query in snmpquery dir,imported 2 xml files.
Change step from 60 to 300 and heartbeat to 600.
My polling cycle is every 1min.
And i cant seem to create even rrds with Create Graphs
My rrd debug says:
RRDTool Command:

/usr/bin/rrdtool graph - \
--imgformat=PNG \
--start=-86400 \
--end=-300 \
--title="R1 - CFEB 0 Internet Processor II - Buffer Utilisation" \
--rigid \
--base=1000 \
--height=120 \
--width=500 \
--alt-autoscale-max \
--lower-limit=0 \
--vertical-label="percent" \
--slope-mode \
DEF:a="/usr/local/apache/htdocs/cacti/rra/r1_fru_buffers_3336.rrd":fru_buffers:AVERAGE \
DEF:b="/usr/local/apache/htdocs/cacti/rra/r1_fru_buffers_3336.rrd":fru_buffers:AVERAGE \
AREA:b#FFC3C0:"" \
LINE2:b#FF3932:"Buffer Utilisation" \
GPRINT:b:LAST:"Current\:%8.0lf" \
GPRINT:b:AVERAGE:"Average\:%8.0lf" \
GPRINT:b:MAX:"Maximum\:%8.0lf"

RRDTool Says:

ERROR: opening '/usr/local/apache/htdocs/cacti/rra/r1_fru_buffers_3336.rrd': No such file or directory

----
I have M10i router ,the interfaces and uptime graphs are working great.
Anyone has made through with those scripts?
Please reply
Peter
dkarpekin
Posts: 5
Joined: Fri Jan 14, 2011 4:16 pm

Re: Juniper FRU statistics

Post by dkarpekin »

Hi all.
Can someone pinpoint me where I can get CPU/Memory template for Juniper MX960/320 ?
Or how difficult it cand be building yourself, as describe here
http://forums.cacti.net/viewtopic.php?t ... ht=juniper
vacky
Posts: 7
Joined: Wed Apr 06, 2011 3:41 pm

Re: Juniper FRU statistics

Post by vacky »

well gr8 this just work fine

i have got every thing running but i observe a graph naming problem

graph for daily working fine but with the name hourly(1 minute average)

same for hourly it say graph for daily (5 minute average)

can you please solve this
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest