network map

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

Moderators: Developers, Moderators

Post Reply
Flying George
Posts: 1
Joined: Sun Jun 19, 2005 3:28 am

Post by Flying George »

Thanks to Howie for your weather!
When I use weathermap,I can't display device icon but your document have ICON section. Something wrong in my weathermap?
User avatar
TFC
Cacti Pro User
Posts: 739
Joined: Wed Apr 09, 2003 2:17 am
Location: Izmir/Turkey

Post by TFC »

Thanks God and Howie :lol:
Finally i solve all the problem and I can see the map correctly.
Last two aesthetic questions:
1.) When I use icon, I can't see the label. Why?

2.) Where can I find turkey map? I see france and other country map drawing briefly...
User avatar
TFC
Cacti Pro User
Posts: 739
Joined: Wed Apr 09, 2003 2:17 am
Location: Izmir/Turkey

Post by TFC »

Another problem is described here:
[root@cacti-test /]# pwd
/
[root@cacti-test /]# /www/htdocs/cacti/rra/weathermap.php --htmloutput /www/htdocs/cacti/rra/test.html

Warning: fopen(weathermap.conf): failed to open stream: No such file or directory in /www/htdocs/cacti/rra/Weathermap.class.php on line 709
Couldn't open config file weathermap.conf for reading
[root@cacti-test /]# cd /www/htdocs/cacti/rra
[root@cacti-test rra]# ./weathermap.php --htmloutput test.html
How can write this in crontab?
User avatar
Pumpi
Cacti User
Posts: 259
Joined: Wed Jan 14, 2004 3:23 am
Location: Germany

Post by Pumpi »

TFC,

I had the same problem with my crontab. I never get an updated map via cron so I switched to Weathermap4RRD which does not need any sheduled cron jobs to get an actuall map.

The only thing I miss is the overlib plugin function from Howie's solution.
User avatar
TFC
Cacti Pro User
Posts: 739
Joined: Wed Apr 09, 2003 2:17 am
Location: Izmir/Turkey

Post by TFC »

Pumpi wrote:TFC,

I had the same problem with my crontab. I never get an updated map via cron so I switched to Weathermap4RRD which does not need any sheduled cron jobs to get an actuall map.

The only thing I miss is the overlib plugin function from Howie's solution.
here is the script:

Code: Select all

[root@cacti-test scripts]# more wm.sh 
#!/bin/bash

pth=`pwd`

cd /www/htdocs/cacti/rra
./weathermap.php --htmloutput test.html
echo `date` html creation is succeded! 

cd $pth
then add crontab this script

Code: Select all

*/5 * * * * /root/scripts/wm.sh > /root/scripts/wm.log 2>&1
User avatar
TFC
Cacti Pro User
Posts: 739
Joined: Wed Apr 09, 2003 2:17 am
Location: Izmir/Turkey

Post by TFC »

Hi in howie's code, I have an warning like this:
Data is not most recent entry (3) for link: internet_router_1_traffic_in_67.rrd
What does it mean?
How can I solve if a problem exists.
User avatar
NHDave
Cacti User
Posts: 61
Joined: Sun Mar 20, 2005 9:14 am
Contact:

Post by NHDave »

Searched for a solution to my problem and have not seen this particular problem posted(unless I'm blind which is entirely possible) so here it is.
I am trying to create multiple 'wmaps' with 2 different config files and 2 cron jobs but the second keeps overwriting the first.

The cron job "php /var/www/html/stats/cacti/wmap/weathermap.php --config wmap.conf --htmloutput index.html" creates my overall network map and then "php /var/www/html/stats/cacti/wmap/weathermap.php --config la.conf --htmloutput la.html" creates a local map for one of my remote sites.

Any ideas why one overwrites the other?


Dave
User avatar
TFC
Cacti Pro User
Posts: 739
Joined: Wed Apr 09, 2003 2:17 am
Location: Izmir/Turkey

Post by TFC »

NHDave wrote:Searched for a solution to my problem and have not seen this particular problem posted(unless I'm blind which is entirely possible) so here it is.
I am trying to create multiple 'wmaps' with 2 different config files and 2 cron jobs but the second keeps overwriting the first.

The cron job "php /var/www/html/stats/cacti/wmap/weathermap.php --config wmap.conf --htmloutput index.html" creates my overall network map and then "php /var/www/html/stats/cacti/wmap/weathermap.php --config la.conf --htmloutput la.html" creates a local map for one of my remote sites.

Any ideas why one overwrites the other?


Dave
This is exactly what i am gonna do...
User avatar
Howie
Cacti Guru User
Posts: 5508
Joined: Thu Sep 16, 2004 5:53 am
Location: United Kingdom
Contact:

Post by Howie »

NHDave wrote:Searched for a solution to my problem and have not seen this particular problem posted(unless I'm blind which is entirely possible) so here it is.
I am trying to create multiple 'wmaps' with 2 different config files and 2 cron jobs but the second keeps overwriting the first.

The cron job "php /var/www/html/stats/cacti/wmap/weathermap.php --config wmap.conf --htmloutput index.html" creates my overall network map and then "php /var/www/html/stats/cacti/wmap/weathermap.php --config la.conf --htmloutput la.html" creates a local map for one of my remote sites.

Any ideas why one overwrites the other?
You need to use the --output option too, otherwise both runs will create a weathermap.png...

I'm thinking that it might be a good idea to allow you to set the two output filenames in the config file, actually, to make the command-lines a bit simpler.
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!)
User avatar
NHDave
Cacti User
Posts: 61
Joined: Sun Mar 20, 2005 9:14 am
Contact:

Post by NHDave »

Howie wrote:You need to use the --output option too, otherwise both runs will create a weathermap.png...
That worked. Didn't realize it created a default weathermap.png.
Howie wrote:I'm thinking that it might be a good idea to allow you to set the two output filenames in the config file, actually, to make the command-lines a bit simpler.
Or put them all in one script and run that from cron.

Nice work Howie!
AK-Whitehawk
Posts: 14
Joined: Wed Jun 08, 2005 2:35 pm

Post by AK-Whitehawk »

I am having a strange problem with my weathermap. I'm going to apologize in advance if this has been asked before. My weathermap works perfectly when traffic on the links I am measuring stays above roughly 50K. Once it drops below that 50K mark the data is no longer correct and the arrow has no color. My cacti graphs are working correctly, no fruityness there. I am running everything on a WindowsXP Home box.

Any ideas?

thx

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

Post by Howie »

AK-Whitehawk wrote:My weathermap works perfectly when traffic on the links I am measuring stays above roughly 50K. Once it drops below that 50K mark the data is no longer correct and the arrow has no color. My cacti graphs are working correctly, no fruityness there. I am running everything on a WindowsXP Home box.
What do you have the BANDWIDTH set to for that link, and what are the bottom few elements of your SCALE? Come to that, which weathermap version? :-)

My guess would be that you are dropping below 1% of your link speed... If it's php-weathermap, then the most recent (0.5a) version allows for decimals in the SCALE so you can have a 0.1-0.5 etc.
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!)
AK-Whitehawk
Posts: 14
Joined: Wed Jun 08, 2005 2:35 pm

Post by AK-Whitehawk »

I am using version 0.5a and the bandwidth statements are between 512K and 1M. However, my scale starts at 1% so I think you are absolutely right that I am dropping below the 1% mark. I will try and define my scale to include the less than 1% measurements.

Thanks for the help.

A-
luckyksc
Posts: 22
Joined: Tue Apr 19, 2005 5:24 pm

Post by luckyksc »

Hi Howie,

First I want to say thank you for your version of php05a.

I had trouble getting 'gd' extension to work in unix so I did it in windows. Using your php05a version, I was able to get everything to work except I am not getting any data on the graph produce. The OVERLIBGRAPH works fine. I was able to get data when I use Weathermap4RRD, but that doesn't have overlibgraph.

I used the command: php weathermap.php --config example.conf --output weather1.png --htmloutput index.html

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

Post by Howie »

luckyksc wrote: was able to get everything to work except I am not getting any data on the graph produce.
I don't understand... Do you mean that you just get grey arrows? Do you get any error message? Have you tried the --debug option?
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!)
Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests