PHP Network Weathermap 0.8 (now 0.9)

Support questions about the Network Weather Map plugin

Moderators: Developers, Moderators

Post Reply
knobdy
Cacti User
Posts: 495
Joined: Wed Sep 28, 2005 1:39 pm

Post by knobdy »

Howie wrote: You need to add a TITLEPOS line. The default TITLEPOS is -1,-1, which is 'off'. This is because the TITLE existed a few versions ago, just to be used by the editor, and it's only in 0.8 that you can show it on-screen, so I defaulted it to not shown, so as not to break any existing maps.
Interesting, it won't take a 0 position, but:

Code: Select all

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

Post by Howie »

knobdy wrote:
Howie wrote: You need to add a TITLEPOS line. The default TITLEPOS is -1,-1, which is 'off'. This is because the TITLE existed a few versions ago, just to be used by the editor, and it's only in 0.8 that you can show it on-screen, so I defaulted it to not shown, so as not to break any existing maps.
Interesting, it won't take a 0 position, but:

Code: Select all

TITLEPOS 1 20
works...
OK. That's tweaked to allow 0 in the dev version.
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!)
slander
Posts: 32
Joined: Thu Mar 16, 2006 12:01 pm

Can I avoid this?

Post by slander »

I have some of my bottom level INFOURLs set to be "telnet host" in version 7, not under cacti control. Works great. In fact, depending on the host, some are set to putty (ssh) or https, or whatever.

Under V8, and cacti control, with a config like this:

INFOURL telnet:192.168.2.190

I get a click button more like this:

http://myhost/mycacti/weathermap/telnet:192.168.2.190, which obviously wont work....

Is there any way to override the prepended stuff? I expect that it is part of the system security - but, still, a pain!
lorcs
Posts: 14
Joined: Thu Oct 20, 2005 2:27 am

Problem with Weathermap 0.5

Post by lorcs »

I just install weathermap 0.8beta4 in my Cacti(0.86h) in Fedora 4 as a plugin. The Weathermap can successfully generated a png file and put in in output folder. However, when I log on to cacti and under the weathermap tab, cacti complain "(thumbnail for map 4 not created yet)" but I can see the png file created and updated in the output folder.

I would be appreciated if anyone can tell me what's wrong with my installation ?

Best Regards

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

Re: Can I avoid this?

Post by Howie »

slander wrote: Is there any way to override the prepended stuff? I expect that it is part of the system security - but, still, a pain!
Nothing is prepended. That would be done by the browser because it thinks that telnet:blah.blah is a relative link. I'm pretty sure it should really be telnet://blah.blah.com/ - that certainly works for me in Safari.

ssh:// also works for me, incidentally.
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
Howie
Cacti Guru User
Posts: 5508
Joined: Thu Sep 16, 2004 5:53 am
Location: United Kingdom
Contact:

Re: Problem with Weathermap 0.5

Post by Howie »

lorcs wrote:I just install weathermap 0.8beta4 in my Cacti(0.86h) in Fedora 4 as a plugin. The Weathermap can successfully generated a png file and put in in output folder. However, when I log on to cacti and under the weathermap tab, cacti complain "(thumbnail for map 4 not created yet)" but I can see the png file created and updated in the output folder.

I would be appreciated if anyone can tell me what's wrong with my installation ?
You should get *two* images for each map - a thumbnail and a fullsize image. It sounds like the thumbnail isn't being created for some reason. A work-around would be to change the weathermap view style to 'Full Images' in the Misc section of Cacti's settings. That would not try and use thumbnails then.

Do you get any error in the Apache error_log or Cacti's log?

It sounds like the imagecopyresampled() function doesn't exist in your php/gd installation. I have FC4 on one of my desktop systems though, and I do get thumbnails with no trouble.
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!)
phantom_rgs
Posts: 41
Joined: Mon Jan 16, 2006 7:44 am
Location: Brasil
Contact:

How to add images/icons?

Post by phantom_rgs »

Hi folks!
I want to upload my images, i have exported then in visio 2003, in attachment to yours.

need help. thanks!!
Attachments
images.zip
(81.39 KiB) Downloaded 266 times
Flavio Humberto Barcellos Dietze
MCP - MCDST - MCTS:SQL 2005 - CCA - MCSA - MCSE: Messaging & Security
User avatar
Howie
Cacti Guru User
Posts: 5508
Joined: Thu Sep 16, 2004 5:53 am
Location: United Kingdom
Contact:

Re: How to add images/icons?

Post by Howie »

phantom_rgs wrote:Hi folks!
I want to upload my images, i have exported then in visio 2003, in attachment to yours.

need help. thanks!!
You need to convert these images from JPEG to PNG, so you can use them for ICON lines in NODEs. Try something like
Image Converter to do that.

They also look like they are probably copyright Microsoft (unless you are a good artist!) so I would say don't post them on the forum!
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!)
lorcs
Posts: 14
Joined: Thu Oct 20, 2005 2:27 am

Re: Problem with Weathermap 0.5

Post by lorcs »

Howie wrote:
lorcs wrote:I just install weathermap 0.8beta4 in my Cacti(0.86h) in Fedora 4 as a plugin. The Weathermap can successfully generated a png file and put in in output folder. However, when I log on to cacti and under the weathermap tab, cacti complain "(thumbnail for map 4 not created yet)" but I can see the png file created and updated in the output folder.

I would be appreciated if anyone can tell me what's wrong with my installation ?
You should get *two* images for each map - a thumbnail and a fullsize image. It sounds like the thumbnail isn't being created for some reason. A work-around would be to change the weathermap view style to 'Full Images' in the Misc section of Cacti's settings. That would not try and use thumbnails then.

Do you get any error in the Apache error_log or Cacti's log?

It sounds like the imagecopyresampled() function doesn't exist in your php/gd installation. I have FC4 on one of my desktop systems though, and I do get thumbnails with no trouble.
I didn't get any error from Cacti log or Apache. However, I do find out the png file generated has no content. Is it possible because of configuration ? If the configuration is incorrect, does weathermap still generate png file except html ?

Thanks a lot

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

Re: Problem with Weathermap 0.5

Post by Howie »

lorcs wrote:I didn't get any error from Cacti log or Apache. However, I do find out the png file generated has no content. Is it possible because of configuration ? If the configuration is incorrect, does weathermap still generate png file except html ?
Has no content as in blank, or 0 bytes? :-?

Most configuration errors cause an error in the Cacti log, and usually they only affect the node or link that it is within. You would have to have an error in ALL the nodes to get a blank map... (that would make the links break too, because the nodes were ignored).

You may want to turn DEBUG on for one poller cycle in Cacti, and look at the logs then. You might also try using the command-line tool from the plugins/weathermap directory:

Code: Select all

php ./weathermap --config configs/yourmap.conf
and if you don't get any errors:

Code: Select all

php ./weathermap --config configs/yourmap.conf --debug
If there's still nothing, then I'd like a copy of your config, please :-) (either PM me or e-mail)

You should still get two PNG files, though: weathermap_1.png and weathermap_thumb_1.png
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!)
lorcs
Posts: 14
Joined: Thu Oct 20, 2005 2:27 am

Re: Problem with Weathermap 0.5

Post by lorcs »

Howie wrote:
lorcs wrote:I didn't get any error from Cacti log or Apache. However, I do find out the png file generated has no content. Is it possible because of configuration ? If the configuration is incorrect, does weathermap still generate png file except html ?
Has no content as in blank, or 0 bytes? :-?

Most configuration errors cause an error in the Cacti log, and usually they only affect the node or link that it is within. You would have to have an error in ALL the nodes to get a blank map... (that would make the links break too, because the nodes were ignored).

You may want to turn DEBUG on for one poller cycle in Cacti, and look at the logs then. You might also try using the command-line tool from the plugins/weathermap directory:

Code: Select all

php ./weathermap --config configs/yourmap.conf
and if you don't get any errors:

Code: Select all

php ./weathermap --config configs/yourmap.conf --debug
If there's still nothing, then I'd like a copy of your config, please :-) (either PM me or e-mail)

You should still get two PNG files, though: weathermap_1.png and weathermap_thumb_1.png
Howie,

I am able to generate png file shows the network map with --output option. However, when I execute the php ./weathermap command without the --output option, I can't see any file generates inside the weathermap folder or the output folder. There is also no error complained from the debug.

Best Regards

Raymond Lo
lorcs
Posts: 14
Joined: Thu Oct 20, 2005 2:27 am

Re: Problem with Weathermap 0.5

Post by lorcs »

Howie wrote:
lorcs wrote:I didn't get any error from Cacti log or Apache. However, I do find out the png file generated has no content. Is it possible because of configuration ? If the configuration is incorrect, does weathermap still generate png file except html ?
Has no content as in blank, or 0 bytes? :-?

Most configuration errors cause an error in the Cacti log, and usually they only affect the node or link that it is within. You would have to have an error in ALL the nodes to get a blank map... (that would make the links break too, because the nodes were ignored).

You may want to turn DEBUG on for one poller cycle in Cacti, and look at the logs then. You might also try using the command-line tool from the plugins/weathermap directory:

Code: Select all

php ./weathermap --config configs/yourmap.conf
and if you don't get any errors:

Code: Select all

php ./weathermap --config configs/yourmap.conf --debug
If there's still nothing, then I'd like a copy of your config, please :-) (either PM me or e-mail)

You should still get two PNG files, though: weathermap_1.png and weathermap_thumb_1.png
Here is the log from cacti.log

04/10/2006 03:09:57 AM - SYSTEM STATS: Time:293.1732 Method:cactid Processes:1 Threads:20 Hosts:9 HostsPerProcess:9 DataSources:70 RRDsProcessed:3
04/10/2006 03:09:57 AM - WEATHERMAP: Poller[0] Weathermap 0.8 in da house
04/10/2006 03:09:57 AM - WEATHERMAP: Poller[0] Map: /var/www/html/cacti/plugins/weathermap/configs//test.conf -> /var/www/html/cacti/plugins/weathermap/output//weathermap_8.html & /var/www/html/cacti/plugins/weathermap/output//weathermap_8.png
04/10/2006 03:09:58 AM - WEATHERMAP: Poller[0] Weathermap 0.8 in da house
04/10/2006 03:09:58 AM - WEATHERMAP: Poller[0] Map: /var/www/html/cacti/plugins/weathermap/configs//test.conf -> /var/www/html/cacti/plugins/weathermap/output//weathermap_8.html & /var/www/html/cacti/plugins/weathermap/output//weathermap_8.png



And the debug from execute ./weathermap

Setting bandwidth (100M, 100M)
Saving Default Link: DEFAULT
Saving Node: eah
Saving Node: core
Saving Node: liatt
Setting bandwidth (512k, 512k)
RRDTOOL check triggered
Saving Link: eah-core
Setting bandwidth (512K, 512K)
Saving Link: liatt-core
Adding default SCALE set.
================== ReadData: Updating link data for all links


ReadData for Link eah-core:
New Target: /var/www/html/cacti/rra/eah_traffic_in_125.rrd (/var/www/html/cacti/rra/eah_traffic_in_125.rrd)
ReadData: Updating link eah-core from RRD Target /var/www/html/cacti/rra/eah_traffic_in_125.rrd
ReadFromRRD: Target DS names are traffic_in and traffic_out
ReadFromRRD: Running: /usr/local/rrdtool-1.2.12/bin/rrdtool fetch /var/www/html/cacti/rra/eah_traffic_in_125.rrd AVERAGE --start now-400
> 1144609200: 1.3512094968e+02 1.5279578662e+01
> 1144609500: nan nan
> --
--1144609500: nan nan

ReadFromRRD: 1: This isn't a number: [nan]
ReadFromRRD: 2: This isn't a number: [nan]
--1144609200: 1.3512094968e+02 1.5279578662e+01

ReadFromRRD: Found a good line: 1144609200: 1.3512094968e+02 1.5279578662e+01
( traffic_in traffic_out
)
ReadFromRRD: Our line is 1144609200: 1.3512094968e+02 1.5279578662e+01

ReadFromRRD: Returning (1080.96759744,122.236629296)
ReadData: Setting 1080.96759744,122.236629296


ReadData for Link liatt-core:
New Target: /var/www/html/cacti/rra/liatt_traffic_in_126.rrd (/var/www/html/cacti/rra/liatt_traffic_in_126.rrd)
ReadData: Updating link liatt-core from RRD Target /var/www/html/cacti/rra/liatt_traffic_in_126.rrd
ReadFromRRD: Target DS names are traffic_in and traffic_out
ReadFromRRD: Running: /usr/local/rrdtool-1.2.12/bin/rrdtool fetch /var/www/html/cacti/rra/liatt_traffic_in_126.rrd AVERAGE --start now-400
> 1144609200: 2.8310012333e+01 1.5865853176e+02
> 1144609500: nan nan
> --
--1144609500: nan nan

ReadFromRRD: 1: This isn't a number: [nan]
ReadFromRRD: 2: This isn't a number: [nan]
--1144609200: 2.8310012333e+01 1.5865853176e+02

ReadFromRRD: Found a good line: 1144609200: 2.8310012333e+01 1.5865853176e+02
( traffic_in traffic_out
)
ReadFromRRD: Our line is 1144609200: 2.8310012333e+01 1.5865853176e+02

ReadFromRRD: Returning (226.480098664,1269.26825408)
ReadData: Setting 226.480098664,1269.26825408

ReadData Completed.
--------------
AllocateScaleColours: KEYTEXT (0,0,0)
AllocateScaleColours: KEYBG (255,255,255)
AllocateScaleColours: BG (255,255,255)
AllocateScaleColours: TITLE (0,0,0)
AllocateScaleColours: TIME (0,0,0)
AllocateScaleColours: 1:10 (140,0,255)
AllocateScaleColours: 10:25 (32,32,255)
AllocateScaleColours: 25:40 (0,192,255)
AllocateScaleColours: 40:55 (0,240,0)
AllocateScaleColours: 55:70 (240,240,0)
AllocateScaleColours: 70:85 (255,192,0)
AllocateScaleColours: 85:100 (255,0,0)
Clipped 211.126483875% to 100%
Adding Poly imagemap for eah-core
Adding Poly imagemap for eah-core
Adding Poly imagemap for liatt-core
Adding Poly imagemap for liatt-core
Node->Draw: Metrics are: 3 21 x 13 -> 21 x 13
Node->Draw: Metrics are: 3 28 x 13 -> 28 x 13
Node->Draw: Metrics are: 3 35 x 13 -> 35 x 13
phantom_rgs
Posts: 41
Joined: Mon Jan 16, 2006 7:44 am
Location: Brasil
Contact:

Images

Post by phantom_rgs »

Where i have to put images/icons to select then in web editor?
Flavio Humberto Barcellos Dietze
MCP - MCDST - MCTS:SQL 2005 - CCA - MCSA - MCSE: Messaging & Security
User avatar
ScOp3
Cacti User
Posts: 61
Joined: Wed Aug 03, 2005 4:14 am
Location: Cologne Germany
Contact:

Re: Images

Post by ScOp3 »

phantom_rgs wrote:Where i have to put images/icons to select then in web editor?
Just put them in the images folder and edit you're conf file. AFAIK you can't assign the pics in the editor yet.

Code: Select all

NODE yaddayadda123
LABEL xyz
ICON images/<you're image>.png
fear leads to anger, anger leads to hate and dancing leads to sex!
User avatar
Howie
Cacti Guru User
Posts: 5508
Joined: Thu Sep 16, 2004 5:53 am
Location: United Kingdom
Contact:

Re: Problem with Weathermap 0.5

Post by Howie »

lorcs wrote:Here is the log from cacti.log

04/10/2006 03:09:57 AM - SYSTEM STATS: Time:293.1732 Method:cactid Processes:1 Threads:20 Hosts:9 HostsPerProcess:9 DataSources:70 RRDsProcessed:3
04/10/2006 03:09:57 AM - WEATHERMAP: Poller[0] Weathermap 0.8 in da house
04/10/2006 03:09:57 AM - WEATHERMAP: Poller[0] Map: /var/www/html/cacti/plugins/weathermap/configs//test.conf -> /var/www/html/cacti/plugins/weathermap/output//weathermap_8.html & /var/www/html/cacti/plugins/weathermap/output//weathermap_8.png
04/10/2006 03:09:58 AM - WEATHERMAP: Poller[0] Weathermap 0.8 in da house
04/10/2006 03:09:58 AM - WEATHERMAP: Poller[0] Map: /var/www/html/cacti/plugins/weathermap/configs//test.conf -> /var/www/html/cacti/plugins/weathermap/output//weathermap_8.html & /var/www/html/cacti/plugins/weathermap/output//weathermap_8.png
This is a strange log!

First, I think you have a problem with cactid - it should run for so long with only 90 hosts. I suggest you disable weathermap and see what is going on with cactid first. 293 seconds is the maximum time it can run for before the next poller cycle. Usually that is a fault.

Second, you seem to be running weathermap twice! Is it possible that you have the $plugins[] = 'weathermap' in two places in your config?

Third, neither of the weathermaps is finishing correctly. Normally there would be a line saying ' Weathermap has left the building' as the last thing it writes to the log. I think that if you had DEBUG on, you would see more there, including a line like 'If this is the last you see, you need to increase your memory_limit in php.ini'. Turn on DEBUG to verify that, but my guess at the moment is to increase memory_limit to something like 32M in php.ini, and restart apache.

With your command line problem... when you don't have an --output line, the weathermap command line program produces a PNG called weathermap.png and no HTML, by default.
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 1 guest