Cacti (home)ForumsDocumentation
Cacti: offical forums and support
It is currently Fri Mar 24, 2017 11:04 pm

All times are UTC - 5 hours




Post new topic Reply to topic  [ 8 posts ] 
Author Message
 Post subject: Weathermap not show traffic
PostPosted: Tue Jan 10, 2017 10:34 am 
Offline

Joined: Wed Jan 04, 2017 3:13 pm
Posts: 2
My weathermap does not show any traffic on the links.

Below is a configuration file I'm using and the weathermap image.

----- CONFIGURATION FILE
HTMLSTYLE overlib

KEYPOS DEFAULT 662 69 Traffic Load
KEYTEXTCOLOR 0 0 0
KEYOUTLINECOLOR 0 0 0
KEYBGCOLOR 255 255 255
BGCOLOR 255 255 255
TITLECOLOR 0 0 0
TIMECOLOR 0 0 0
SCALE DEFAULT 0 0 192 192 192
SCALE DEFAULT 0 1 255 255 255
SCALE DEFAULT 1 10 140 0 255
SCALE DEFAULT 10 25 32 32 255
SCALE DEFAULT 25 40 0 192 255
SCALE DEFAULT 40 55 0 240 0
SCALE DEFAULT 55 70 240 240 0
SCALE DEFAULT 70 85 255 192 0
SCALE DEFAULT 85 100 255 0 0

#SET key_hidezero_DEFAULT 1
SET rrd_use_poller_output 1

# End of global section

# TEMPLATE-only NODEs:
NODE DEFAULT
MAXVALUE 100

# TEMPLATE-only LINKs:
LINK DEFAULT
BANDWIDTH 100M

# regular NODEs:
NODE JUNIPER_MX480
LABEL JUNIPER_MX480
ICON images/router40.png
POSITION 197 285

NODE BROCADE
LABEL BROCADE
ICON images/router40.png
POSITION 520 288

# regular LINKs:
LINK BROCADE-JUNIPER_MX480
INFOURL /cacti/graph.php?rra_id=all&local_graph_id=3598
OVERLIBGRAPH /cacti/graph_image.php?local_graph_id=3598&rra_id=0&graph_nolegend=true&graph_height=100&graph_width=300
TARGET /usr/share/cacti/rra/bb3_traffic_in_3567.rrd
NODES BROCADE JUNIPER_MX480
BANDWIDTH 10000M

---- END CONFIGURATION FILE

I have tried several configurations and I have no results.

When I try to run the debug on the console I get the following error:

PHP Parse error: syntax error, unexpected T_OBJECT_OPERATOR in / usr / share / cacti / plugins / weathermap / weathermap on line 60

Thank you for any help.


Attachments:
File comment: Weathermap
Untitled.png
Untitled.png [ 25.99 KiB | Viewed 941 times ]
Top
 Profile  
 
 Post subject: Re: Weathermap not show traffic
PostPosted: Thu Jan 19, 2017 3:23 am 
Offline

Joined: Thu Jan 19, 2017 3:19 am
Posts: 3
This will resolve that problem:
https://network-weathermap.com/2016/09/21/5000-downloads-of-0-98-and-progress-on-0-98a/

but then you might end up with this one:
PHP Fatal error: Cannot redeclare rotateAboutPoint() (previously declared in /var/www/html/plugins/weathermap/WeatherMap.functions.php:473) in /var/www/html/plugins/weathermap/lib/geometry.php on line 55

which I cant yet find a solution for. :cry:


Top
 Profile  
 
 Post subject: Re: Weathermap not show traffic
PostPosted: Thu Jan 19, 2017 3:47 am 
Offline
Cacti Guru User
User avatar

Joined: Thu Sep 16, 2004 5:53 am
Posts: 5055
Location: United Kingdom
pgolding wrote:
but then you might end up with this one:
PHP Fatal error: Cannot redeclare rotateAboutPoint() (previously declared in /var/www/html/plugins/weathermap/WeatherMap.functions.php:473) in /var/www/html/plugins/weathermap/lib/geometry.php on line 55

which I cant yet find a solution for. :cry:


Huh? It's a one-line change that doesn't mention rotateAboutPoint... what version are you running, pgolding? And when do you get this error?

It sounds like you have parts of 0.98 and parts of some other version.

_________________
Weathermap 0.98 is out! & QuickTree 0.2. Superlinks is over there now.
Some Other Cacti tweaks, including strip-graphs, icons and snmp/netflow stuff.
(Let me know if you have UK DevOps or Network Ops opportunities, too!)


Top
 Profile  
 
 Post subject: Re: Weathermap not show traffic
PostPosted: Fri Jan 20, 2017 2:29 am 
Offline

Joined: Thu Jan 19, 2017 3:19 am
Posts: 3
installed weathermap 0.98 with cacti 0.8.8a (cactiez), after removing 0.97a, then saw what i posted previusly, via command line debug execution. tried the one line fix, which led us all here! verified php ver was as specified before installing.

tried 0.98 because 0.97a was doing this:

DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:391] configs/xxx.conf: RRD ReadData: Headings are: 5min_cpu
WARNING: configs/xxx.conf: RRD ReadData: At least one of your DS names (5min_cpu and 5min-cpu) were not found, even though there was a valid data line. Maybe they are wrong? Valid DS names in this file are: 5min_cpu, [WMRRD06]

so tried cpu, Cputil, 5min_cpu, 5min-cpu, DS0,DS1,ds0,ds1 which were found on various places, but none seem to work. is there possibly a null appended to the real "5min_cpu" which is causing a comparison to fail and generate the above?

And we started all this because colorizing the node based on measured cpu was just returning a black box with this config (ver 0.97a):
NODE rt1
POSITION 425 100
LABEL RT1
TARGET gauge:../../rra/rt1_5min_cpu_150.rrd:5min_cpu:-

the target line is where all the different combinations (cpu, Cputil, 5min etc) were tested. tried with/without gauge, with inpercent, percent etc (found in various places). verified that the rrd file exists. manual rrd fetch returns good numbers.

hope i've not messed up the install smashing different versions together?


maybe should add: 0.97a was not giving the node cpu colorisation, so tried 0.98, found and made the one line fix, then no more updated weathermaps. debug then gave us the rotateAboutPoint error in the previous post. tried commenting the rotate function declaration out in both places it occurs (one at a time!) but it just threw different errors for each so i gave up on that approach.


Top
 Profile  
 
 Post subject: Re: Weathermap not show traffic
PostPosted: Fri Jan 20, 2017 3:07 am 
Offline
Cacti Guru User
User avatar

Joined: Thu Sep 16, 2004 5:53 am
Posts: 5055
Location: United Kingdom
OK, so based on your log lines there, this target is correct:
Code:
   TARGET   gauge:../../rra/rt1_5min_cpu_150.rrd:5min_cpu:-


If you run with debugging again (once the other thing is fixed), you'll see what data it's actually receiving, and hopefully get a clue about why it's black.

The reason you got that first message is that only one of your two DS names exists in that file (5min_cpu does, 5min-cpu doesn't), so that's reasonable. It does tell you what the valid DS names are on the end of the message (i.e. ds0, DS0, cputil was never going to work)

As for the other error - these are functions that were broken out into smaller files between 0.97a and 0.98, so I'd delete (or rename) the lib/ directory and unpack it from the 0.98 zip to make sure you only have one version.

_________________
Weathermap 0.98 is out! & QuickTree 0.2. Superlinks is over there now.
Some Other Cacti tweaks, including strip-graphs, icons and snmp/netflow stuff.
(Let me know if you have UK DevOps or Network Ops opportunities, too!)


Top
 Profile  
 
 Post subject: Re: Weathermap not show traffic
PostPosted: Fri Jan 20, 2017 3:04 pm 
Offline

Joined: Wed Jan 04, 2017 3:13 pm
Posts: 2
ThankĀ“s for help...

$ret=$cg->getopt($args, $short_opts, $long_opts);

-if ((new PEAR)->isError($ret)) { die ("Error in command line: " . $ret->getMessage() . "\n (try --help)\n"); }
+$pear = new PEAR;
+if ($pear->isError($ret)) { die ("Error in command line: " . $ret->getMessage() . "\n (try --help)\n"); }

$gopts=$ret[0];

This works great to correct the PHP Parse error: syntax error, unexpected T_OBJECT_OPERATOR in / usr / share / cacti / plugins / weathermap / weathermap on line 60

But graphics still without color and does not show any traffic on the links.


Top
 Profile  
 
 Post subject: Re: Weathermap not show traffic
PostPosted: Sat Jan 21, 2017 5:56 am 
Offline
Cacti Guru User
User avatar

Joined: Thu Sep 16, 2004 5:53 am
Posts: 5055
Location: United Kingdom
OK, so back to basics, now that it is running:

What do the logs say? If data can't be collected, there will be some kind of error message.

_________________
Weathermap 0.98 is out! & QuickTree 0.2. Superlinks is over there now.
Some Other Cacti tweaks, including strip-graphs, icons and snmp/netflow stuff.
(Let me know if you have UK DevOps or Network Ops opportunities, too!)


Top
 Profile  
 
 Post subject: Re: Weathermap not show traffic
PostPosted: Mon Jan 23, 2017 1:26 am 
Offline

Joined: Thu Jan 19, 2017 3:19 am
Posts: 3
thanks Howie, thats resolved my issue.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 8 posts ] 

All times are UTC - 5 hours


Who is online

Users browsing this forum: No registered users and 5 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  

Protected by Anti-Spam ACP Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group