weather map editor issue

Support questions about the Network Weather Map plugin

Moderators: Developers, Moderators

briodan
Posts: 22
Joined: Fri Apr 10, 2009 9:21 pm

weather map editor issue

Post by briodan »

I just installed weathermap this afternoon and i'm having a number of issues that i'm not sure how to fix:

I'm using the Cacti plugin, the latest version.

My problem is the the editor is not working at all.
When attempting to add a new node to a blank map i get all kinds of errors.
When i'm using firefox the browser attempts to download editor.php
When using IE the browser tells me it can not display the web page
When using Safari gives me an operation can not be completed error.

i thought it might have been related to the sticky at the top of the forum but i applied the fix and it did not solve the issue.
User avatar
Howie
Cacti Guru User
Posts: 5508
Joined: Thu Sep 16, 2004 5:53 am
Location: United Kingdom
Contact:

Post by Howie »

So...
which version of weathermap?
which version of cacti?
which operating system?
which GD (php built-in or external library)?

does check.php show any issues?
is there anything in your apache error 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!)
briodan
Posts: 22
Joined: Fri Apr 10, 2009 9:21 pm

Post by briodan »

Cacti Version - 0.8.7d
Weathermap version - 0.95b
OS - Ubuntu 7.10
GD - external

Check.php shows the following errors:
imagefilter() X non-critical This is required for colorizing icons. It is a special function of the PHP-supplied GD library ONLY (not the external GD library that you are using).
imagettfbbox() X non-critical This is required for TrueType font support. It is an optional part of the GD library and the "gd" PHP extension

The apache log does not display anything related to the weathermap plugin.
User avatar
Howie
Cacti Guru User
Posts: 5508
Joined: Thu Sep 16, 2004 5:53 am
Location: United Kingdom
Contact:

Post by Howie »

And you don't get any errors about child segmentation faults in the apache log?

Also, what does http://yourcacti/plugins/weathermap/check-gdbug.php say?

Your setup, and the problem description sounds like the GD bug that affects several debian and ubuntu distros.
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!)
briodan
Posts: 22
Joined: Fri Apr 10, 2009 9:21 pm

Post by briodan »

i used to have the segmentation faults in apache's log until i applied the fix from the sticky.
The errors have disappeared but the issue continues
I can run check-gdbug.php it's presenting the same issues i get when trying to edit a map.
User avatar
Howie
Cacti Guru User
Posts: 5508
Joined: Thu Sep 16, 2004 5:53 am
Location: United Kingdom
Contact:

Post by Howie »

OK. You should also try running check.php from the browser, the same way. Debian/Ubuntu has different configuration files for the command-line and web-based versions of PHP. It's possible for one to be OK, but the other be broken.

Incidentally, do maps get generated OK? If you just set Cacti to use simple.conf, does it actually produce a map (after 5 minutes)?

There are very few things that actually crash weathermap with no output like this - neither of the two I know are actually weathermap: buggy GD, or low memory_limit in php.ini.
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!)
briodan
Posts: 22
Joined: Fri Apr 10, 2009 9:21 pm

Post by briodan »

this is what i get when running check.php from the command line.

php: /usr/local/groundwork/lib/libdb-4.4.so: no version information available (required by php)

----------------------------------------------------
Weathermap Pre-Install Checker

This script checks for some common problems with your PHP and server
environment that may stop Weathermap or the Editor from working.

NOTE: You should run this script as both a web page AND from the
command-line, as the environment can be different in each.

This is the PHP version that is responsible for
* creating maps from the Cacti poller
* the command-line weathermap tool

PHP Basics
----------
This is PHP Version 5.2.3-1ubuntu6.5 running on "Linux gtca-mon2
2.6.22-14-server #1 SMP Sun Oct 14 23:34:23 GMT 2007 i686" with a
memory_limit of '128M'.

The php.ini file was /etc/php5/cli
The following additional ini files were read: /etc/php5/cli/conf.d/mysql.ini,
/etc/php5/cli/conf.d/mysqli.ini,
/etc/php5/cli/conf.d/pdo.ini,
/etc/php5/cli/conf.d/pdo_mysql.ini


PHP Functions
-------------
Some parts of Weathermap need special support in your PHP
installation to work.

The gdinfo() function is not available, which means that either the GD
extension is not available, not enabled, or not installed.

The Console_Getopt PEAR module is not available. The CLI weathermap tool
will not run without it (that may not be a problem, if you only intend to
use Cacti).

imagepng NO CRITICAL. This is required for all of
Weathermap. It is part of the GD library and the
"gd" PHP extension.
imagecreatetruecolor NO CRITICAL. This is required for all of
Weathermap. It is part of the GD library and the
"gd" PHP extension.
imagealphablending NO CRITICAL. This is required for all of
Weathermap. It is part of the GD library and the
"gd" PHP extension.
imageSaveAlpha NO CRITICAL. This is required for all of
Weathermap. It is part of the GD library and the
"gd" PHP extension.
preg_match YES
imagecreatefrompng NO CRITICAL. This is required for all of
Weathermap. It is part of the GD library and the
"gd" PHP extension.
imagecreatefromjpeg NO Non-Critical. This is required for JPEG input
support for ICON and BACKGROUND. It is an optional
part of the GD library and the "gd" PHP extension.
imagecreatefromgif NO Non-Critical. This is required for GIF input
support for ICON and BACKGROUND. It is an optional
part of the GD library and the "gd" PHP extension.
imagejpeg NO Non-Critical. This is required for JPEG output
support. It is an optional part of the GD library
and the "gd" PHP extension.
imagegif NO Non-Critical. This is required for GIF output
support. It is an optional part of the GD library
and the "gd" PHP extension.
imagefilter NO Non-Critical. This is required for colorizing
icons. It is a special function of the
PHP-supplied GD library ONLY (not the external GD
library that you are using).
imagecopyresampled NO Non-Critical. This is required for Thumbnail
creation in the Cacti plugin. It is an optional
part of the GD library and the "gd" PHP extension.
imagettfbbox NO Non-Critical. This is required for TrueType font
support. It is an optional part of the GD library
and the "gd" PHP extension.
memory_get_usage YES

If these functions are not found, you may need to
* check that the 'extension=' line for that extension is uncommented in
your php.ini file (then restart your webserver), or
* install the extension, if it isn't installed already

The details of how this is done will depend on your operating system, and
on where you installed (or compiled) your PHP from originally. Usually, you
would install an RPM, or other package on Linux systems, a port on *BSD, or
a DLL on Windows. If you build PHP from source, you need to add extra
options to the './configure' line. Consult your PHP documention for more
information.

---------------------------------------------------------------------
There are problems with your PHP or server environment that will stop
Weathermap from working. You need to correct these issues if you wish to
use Weathermap.


Also the sample.conf map does not generate anything

So i installed the php5-gd library and now check.php from the CLI runs with all OK's so i'll see what else happens.
briodan
Posts: 22
Joined: Fri Apr 10, 2009 9:21 pm

Post by briodan »

Well that did not work.
The maps are not created, nor can create/edit any of the maps.

One think i did notice is that any new maps i create through the editor are owned by the nobody user and once i create then i can no longer edit them.
Could this have anything to do with this?
User avatar
Howie
Cacti Guru User
Posts: 5508
Joined: Thu Sep 16, 2004 5:53 am
Location: United Kingdom
Contact:

Post by Howie »

briodan wrote:Well that did not work.
The maps are not created, nor can create/edit any of the maps.

One think i did notice is that any new maps i create through the editor are owned by the nobody user and once i create then i can no longer edit them.
Could this have anything to do with this?
As long as nobody is the user that runs apache as well, then that's OK. You would see warnings about permissions in cacti.log if weathermap had trouble writing to files that it needed to.

But you don't have GD configured in your php-cli/php.ini - that will definitely stop weathermap working from the poller.

You should also go to check.php in your browser, to check the php-www install.
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!)
briodan
Posts: 22
Joined: Fri Apr 10, 2009 9:21 pm

Post by briodan »

Ok then the permissions are fine.

what do i need to look for in the php.ini file in terms of having GD configured?

I checked the browser config for and it's all OK.
User avatar
Howie
Cacti Guru User
Posts: 5508
Joined: Thu Sep 16, 2004 5:53 am
Location: United Kingdom
Contact:

Post by Howie »

briodan wrote:Ok then the permissions are fine.

what do i need to look for in the php.ini file in terms of having GD configured?

I checked the browser config for and it's all OK.
It varies from installation to installation, but since your www PHP is OK, look in the php-www/php.ini for a line like:
extension=gd.so

and copy that to you php-cli/php.ini

It may have a pathname in there, but it will start "extension="
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!)
briodan
Posts: 22
Joined: Fri Apr 10, 2009 9:21 pm

PHP.ini files

Post by briodan »

Attached are the two php.ini file i found their patch by running phpinfo() from both the cli and the browser.

Neither on of them has a reference or lists extension=gd.so

i did notice that the php-www.ini file has a section for the paths and directories that shows this:
extension_dir = "/usr/local/groundwork/lib/20060613"

now i don't have the folder in that path
but i do have /usr/local/groundwork/lib -> this folder contains a whole bunch of lib*.so including one called libgd.so
and /usr/local/groundwork/20060613 ->this folder contains only two file apc.so and mnogosearch.so

should i just change the path of the extensions directory to point to /usr/local/groundwork/lib ?

Thanks
Attachments
php-cli.txt
file found in /etc/php5/cli/
(43.24 KiB) Downloaded 243 times
php-www.txt
file found in /usr/local/groundwork/etc/
(40.37 KiB) Downloaded 408 times
briodan
Posts: 22
Joined: Fri Apr 10, 2009 9:21 pm

Cacti log file

Post by briodan »

i also checked the cacti log file again and the attached file shows what it's recording.

This is using the example map i have moved all the example files into the weathermap/config directory
Attachments
cacti-weathermap logs.txt
(5.9 KiB) Downloaded 250 times
User avatar
Howie
Cacti Guru User
Posts: 5508
Joined: Thu Sep 16, 2004 5:53 am
Location: United Kingdom
Contact:

Re: Cacti log file

Post by Howie »

briodan wrote:i also checked the cacti log file again and the attached file shows what it's recording.

This is using the example map i have moved all the example files into the weathermap/config directory
That actually looks OK - most of the errors are because the example map refers to rrd files that you don't have. The rest are because the font and background files need to be in the weathermap folder, not the configs folder (i.e. relative paths are relative to weathermap, not configs).

Assuming the map is actually appearing in the Cacti weathermap tab, then that part is working OK. If it isn't check permissions on the output/ directory.
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: PHP.ini files

Post by Howie »

briodan wrote:Attached are the two php.ini file i found their patch by running phpinfo() from both the cli and the browser.

Neither on of them has a reference or lists extension=gd.so

i did notice that the php-www.ini file has a section for the paths and directories that shows this:
extension_dir = "/usr/local/groundwork/lib/20060613"

now i don't have the folder in that path
but i do have /usr/local/groundwork/lib -> this folder contains a whole bunch of lib*.so including one called libgd.so
and /usr/local/groundwork/20060613 ->this folder contains only two file apc.so and mnogosearch.so

should i just change the path of the extensions directory to point to /usr/local/groundwork/lib ?

Thanks
Well, you could try that. It's likely that the other libgd.so is actually the GD library, and not the PHP extension though. You might also want to check for any 'additional .ini files' in that phpinfo output - on FreeBSD there's an extensions.ini, for example.
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