Weathermap Map Refresh

Support questions about the Network Weather Map plugin

Moderators: Developers, Moderators

Post Reply
mercolino
Posts: 25
Joined: Wed Aug 29, 2007 6:14 pm

Weathermap Map Refresh

Post by mercolino »

I installed weathermap, and its working. I create a Map and it's working only when your recalculate the maps with the button in the Console menu weathermap. But when you enter in the weathermap tab, the map is not refreshing automatically. I am running out of ideas.

Thanks for your help
Mercolino
User avatar
Howie
Cacti Guru User
Posts: 5508
Joined: Thu Sep 16, 2004 5:53 am
Location: United Kingdom
Contact:

Re: Weathermap Map Refresh

Post by Howie »

mercolino wrote:I installed weathermap, and its working. I create a Map and it's working only when your recalculate the maps with the button in the Console menu weathermap. But when you enter in the weathermap tab, the map is not refreshing automatically. I am running out of ideas.

Thanks for your help
Mercolino
If you used the recalculate button, then probably the permissions are wrong on the files in the output/ directory. Check the cacti.log file, and it will tell you. chown -R cactiuser output/ will probably fix it. If things ever stop working, there will almost always be some clue in the cacti.log.
Weathermap 0.98a is out! & QuickTree 1.0. Superlinks is over there now (and built-in to Cacti 1.x).
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!)
mercolino
Posts: 25
Joined: Wed Aug 29, 2007 6:14 pm

Re: Weathermap Map Refresh

Post by mercolino »

Howie wrote:
mercolino wrote:I installed weathermap, and its working. I create a Map and it's working only when your recalculate the maps with the button in the Console menu weathermap. But when you enter in the weathermap tab, the map is not refreshing automatically. I am running out of ideas.

Thanks for your help
Mercolino
If you used the recalculate button, then probably the permissions are wrong on the files in the output/ directory. Check the cacti.log file, and it will tell you. chown -R cactiuser output/ will probably fix it. If things ever stop working, there will almost always be some clue in the cacti.log.
I changed the permissions in the Output directory and still I get nothing, in the cacti.log thgere are no references about weather map, only if I activate DEBUG, then there are some references about SQL reading maps in some Tables. Even when I run the command php ./weathermap, no maps are generated in the output directory. i don't know if there is a way where I can tell weathermap to find the configs file and to specify the output folder. Anyway, I edited weathermap and I uncommented the line about debugging, and when I run the script the output is:

Adding default map colour set.
Beginning to load data plugins from lib/datasources
Loading data Plugin class from WeatherMapDataSource_tabfile.php
Loaded data Plugin class WeatherMapDataSource_tabfile from WeatherMapDataSource_tabfile.php
Skipping README.txt
Skipping ..
Loading data Plugin class from WeatherMapDataSource_mrtg.php
Loaded data Plugin class WeatherMapDataSource_mrtg from WeatherMapDataSource_mrtg.php
Loading data Plugin class from WeatherMapDataSource_snmp.php
Loaded data Plugin class WeatherMapDataSource_snmp from WeatherMapDataSource_snmp.php
Loading data Plugin class from WeatherMapDataSource_static.php
Loaded data Plugin class WeatherMapDataSource_static from WeatherMapDataSource_static.php
Loading data Plugin class from WeatherMapDataSource_external.php
Loaded data Plugin class WeatherMapDataSource_external from WeatherMapDataSource_external.php
Loading data Plugin class from WeatherMapDataSource_rrd.php
Loaded data Plugin class WeatherMapDataSource_rrd from WeatherMapDataSource_rrd.php
Skipping .
Loading data Plugin class from WeatherMapDataSource_cactihost.php
Loaded data Plugin class WeatherMapDataSource_cactihost from WeatherMapDataSource_cactihost.php
Loading data Plugin class from WeatherMapDataSource_dbsample.php
Loaded data Plugin class WeatherMapDataSource_dbsample from WeatherMapDataSource_dbsample.php
Beginning to load pre plugins from lib/pre
Loading pre Plugin class from WeatherMapPreProcessorTest.php
Loaded pre Plugin class WeatherMapPreProcessorTest from WeatherMapPreProcessorTest.php
Skipping ..
Skipping .
Beginning to load post plugins from lib/post
Loading post Plugin class from WeatherMapPostProcessorTest.php
Loaded post Plugin class WeatherMapPostProcessorTest from WeatherMapPostProcessorTest.php
Skipping ..
Skipping .
WeatherMap class Reset() complete
Saving Node: node1
Saving Node: node2
Setting bandwidth (30M -> 30000000 bps, 30M -> 30000000 bps, KILO = 1000)
Saving Link: firstlink
Adding default SCALE set.
Cycle 100 - set 0 and Skipped 0 for unresolved dependencies
Running Pre-Processing Plugins...
Running WeatherMapPreProcessorTest->run()
Test Preprocessor in the hizouse
Finished Pre-Processing Plugins...
Running Init() for Data Source Plugins...
Running WeatherMapDataSource_tabfile->Init()
Running WeatherMapDataSource_mrtg->Init()
Running WeatherMapDataSource_snmp->Init()
Running WeatherMapDataSource_static->Init()
Running WeatherMapDataSource_external->Init()
Running WeatherMapDataSource_rrd->Init()
Running WeatherMapDataSource_cactihost->Init()
ReadData CactiHost: Can only run from Cacti environment.
Removing WeatherMapDataSource_cactihost from Data Source list, since Init() failed
Running WeatherMapDataSource_dbsample->Init()
Finished Initialising Plugins...
================== ReadData: Updating link data for all links and nodes


ReadData for LINK firstlink:
ReadData: No targets for LINK firstlink
ReadData: Setting 0,0


ReadData for NODE node1:
ReadData: No targets for NODE node1
ReadData: Setting 0,0


ReadData for NODE node2:
ReadData: No targets for NODE node2
ReadData: Setting 0,0

ReadData Completed.
--------------
Running Post-Processing Plugins...
Running WeatherMapPostProcessorTest->run()
WeatherMapPostProcessorTest Not Enabled
Finished Post-Processing Plugins...
AllocateScaleColours: DEFAULT KEYTEXT (0,0,0)
AllocateScaleColours: DEFAULT KEYBG (255,255,255)
AllocateScaleColours: DEFAULT BG (255,255,255)
AllocateScaleColours: DEFAULT TITLE (0,0,0)
AllocateScaleColours: DEFAULT TIME (0,0,0)
AllocateScaleColours: DEFAULT 1_10 (140,0,255)
AllocateScaleColours: DEFAULT 10_25 (32,32,255)
AllocateScaleColours: DEFAULT 25_40 (0,192,255)
AllocateScaleColours: DEFAULT 40_55 (0,240,0)
AllocateScaleColours: DEFAULT 55_70 (240,240,0)
AllocateScaleColours: DEFAULT 70_85 (255,192,0)
AllocateScaleColours: DEFAULT 85_100 (255,0,0)
Node->pre_render: Label Metrics are: 35 x 13 -> 39 x 17
Node->pre_render: Label Metrics are: 35 x 13 -> 39 x 17
Adding Poly imagemap for firstlink
Adding Poly imagemap for firstlink
Bandwidth is 0
Bandwidth is 0
Drawing KEY for DEFAULT if necessary.
Writing PNG file

i don't know if this could help.
Thanks again
mercolino
User avatar
Howie
Cacti Guru User
Posts: 5508
Joined: Thu Sep 16, 2004 5:53 am
Location: United Kingdom
Contact:

Post by Howie »

The 'weathermap' script only runs one config at a time. You can specify it on the command line, but the default is weathermap.conf in the current directory. It would have created a 'weathermap.png' file in the current directory. You don't need to edit the script to use debug mode, just add --debug to the end. There are lots of options, which are in the Command-Line Reference in the manual.

Anyway, that tells you that most of weathermap is probably working.

Nothing at all in the Cacti logs? You should at least get a "WEATHERMAP Starting" line, even if there are no maps and even in normal logging, unless you have turned on the 'quiet mode' in the Weathermap options (Settings..Misc in Cacti).
Weathermap 0.98a is out! & QuickTree 1.0. Superlinks is over there now (and built-in to Cacti 1.x).
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!)
mercolino
Posts: 25
Joined: Wed Aug 29, 2007 6:14 pm

Post by mercolino »

Howie wrote:The 'weathermap' script only runs one config at a time. You can specify it on the command line, but the default is weathermap.conf in the current directory. It would have created a 'weathermap.png' file in the current directory. You don't need to edit the script to use debug mode, just add --debug to the end. There are lots of options, which are in the Command-Line Reference in the manual.

Anyway, that tells you that most of weathermap is probably working.

Nothing at all in the Cacti logs? You should at least get a "WEATHERMAP Starting" line, even if there are no maps and even in normal logging, unless you have turned on the 'quiet mode' in the Weathermap options (Settings..Misc in Cacti).
I found the problem, finally the errors was shown in the cacti.log and there was an error about permissions in a sessions folder in php.

I am sending my first map.

Thanks for your help
mercolino
Attachments
ScreenHunter_001.JPG
ScreenHunter_001.JPG (108.14 KiB) Viewed 7960 times
User avatar
Howie
Cacti Guru User
Posts: 5508
Joined: Thu Sep 16, 2004 5:53 am
Location: United Kingdom
Contact:

Post by Howie »

Cool :-)

You might want to look at the LABELOFFSET command in the manual though - you can adjust those labels so that they don't all overlap so much.
Weathermap 0.98a is out! & QuickTree 1.0. Superlinks is over there now (and built-in to Cacti 1.x).
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!)
cbrmig
Posts: 14
Joined: Mon Sep 24, 2007 5:02 am

Post by cbrmig »

How can i see the refresh rate of weathermap?
It only makes the refresh, when i click on the refresh buton of my browser...

I already went to the "misc" in cacti, and put th refresh time, and refresh interval in 5sec..

Thks.
User avatar
Howie
Cacti Guru User
Posts: 5508
Joined: Thu Sep 16, 2004 5:53 am
Location: United Kingdom
Contact:

Post by Howie »

cbrmig wrote:How can i see the refresh rate of weathermap?
It only makes the refresh, when i click on the refresh buton of my browser...

I already went to the "misc" in cacti, and put th refresh time, and refresh interval in 5sec..
The refresh time in misc is for the map cycling mode in Weathermap (choose 'automatically cycle' in the top corner).

On the normal or thumbnail displays, Weathermap uses the same refresh time as Cacti itself, which is 300 seconds (5 minutes). I thought you could change that somewhere in the Cacti settings, but I don't see it right now.

None of those things affect when the weathermap is actually recalculated, which is once every poller cycle - usually 5 minutes.
Weathermap 0.98a is out! & QuickTree 1.0. Superlinks is over there now (and built-in to Cacti 1.x).
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!)
trifly
Posts: 3
Joined: Mon Jan 18, 2010 2:02 am

Post by trifly »

Hello mercolino, I have the same problem that you had.

Can you tell me how can you resolve precisely this problem ?
What kind of permissions errors about php ?

Thanks for your help :)
Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests