WeatherMap Not Updating
Moderators: Developers, Moderators
WeatherMap Not Updating
Hi,
First, I apologize for my poor english, it is not my native language.
I have just updated and installed Cacti with WeatherMap.
I have start from a running Linux Box Debian Etch,
Then, I update it to Debian Lenny, remove the Cacti installed by apt-get, and install it manually from tar.
Every things works fine, Traffic from my router, and switch are correctly polled.
I've installed then the PA 2.5 and WeatherMap Plugin.
My poller is executed every 5 min, WeatherMap at the same time.
All the graph are nice no problem.
Now here is my trouble. Maps are generated without data.
So, I have modified some things for permission and use www-data as cacti users, change ownership of directory and try with the Forbiden Button.
It worked, but sometimes not. And I realise that the problem is present only If I tried to update map just after the poller.
If I update 2 min after, no problem. It's like data are not complete when you launch map generation just after the poller.
And, the best for the end, the CPU USAGE is not affected by this problem, onlye the network traffic. My Label are changing color correctly.
Do you have experienced any similar issue ?
First, I apologize for my poor english, it is not my native language.
I have just updated and installed Cacti with WeatherMap.
I have start from a running Linux Box Debian Etch,
Then, I update it to Debian Lenny, remove the Cacti installed by apt-get, and install it manually from tar.
Every things works fine, Traffic from my router, and switch are correctly polled.
I've installed then the PA 2.5 and WeatherMap Plugin.
My poller is executed every 5 min, WeatherMap at the same time.
All the graph are nice no problem.
Now here is my trouble. Maps are generated without data.
So, I have modified some things for permission and use www-data as cacti users, change ownership of directory and try with the Forbiden Button.
It worked, but sometimes not. And I realise that the problem is present only If I tried to update map just after the poller.
If I update 2 min after, no problem. It's like data are not complete when you launch map generation just after the poller.
And, the best for the end, the CPU USAGE is not affected by this problem, onlye the network traffic. My Label are changing color correctly.
Do you have experienced any similar issue ?
- Howie
- Cacti Guru User
- Posts: 5508
- Joined: Thu Sep 16, 2004 5:53 am
- Location: United Kingdom
- Contact:
Stop using the Rebuild Now option. Cacti will update the map by itself if your use the weathermap plugin.
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!)
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!)
- Howie
- Cacti Guru User
- Posts: 5508
- Joined: Thu Sep 16, 2004 5:53 am
- Location: United Kingdom
- Contact:
OK.humanlock wrote:I aren't using it since severals days, I have purge the directory (remove all maps) and waiting.
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!)
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!)
Hello!humanlock wrote:I aren't using it since severals days, I have purge the directory (remove all maps) and waiting.
I have no data for the link, but the CPU label is working.
Just a quick heads up from someone who've used a fair amount of time trying to figure out the exact same thing on a Debian 5 (lenny) system: Why does the "Recalculate now" button work, but not when it is updated from the poller/cli?
Actually I don't have an answer to my own question .... 'cause I really don't know why Debian won't draw all the right link colors and other nifty things in my Weathermaps when it is not being updated from the web gui.
I've upgraded to the latest versions of php5 and php5-gd from http://www.dotdeb.org. I've installed the newest gd-lib (2.0.36) and I've run the script from Howie's weathermap plugin "check.php" - and it all says the same in both cli and via www: ALL OK! But it just doesn't work from the cli!
The way I've done this in Debian is to set the weathermap to never update the maps under "Settings" and instead i've created a new entry in my /etc/cron.d/cacti:
Code: Select all
*/5 * * * * /usr/bin/curl http://localhost/cacti/plugins/weathermap/weathermap-cacti-rebuild.php
Off course you have to fix the above URL if it doesn't match your cacti's installation.
I hope this helps anyone that faced the same problem as I did....
Regards,
Tommy
Code: Select all
mrtg:/usr/share/cacti/site/plugins/weathermap# /usr/bin/curl http://localhost/cacti/plugins/weathermap/weathermap-cacti-rebuild.php
Couldn't find a usable Cacti config<br />
<b>Warning</b>: include_once(/database.php) [<a href='function.include-once'>function.include-once</a>]: failed to open stream: No such file or directory in <b>/usr/share/cacti/site/plugins/weathermap/setup.php</b> on line <b>233</b><br />
<br />
<b>Warning</b>: include_once() [<a href='function.include'>function.include</a>]: Failed opening '/database.php' for inclusion (include_path='.:/usr/share/php:/usr/share/pear') in <b>/usr/share/cacti/site/plugins/weathermap/setup.php</b> on line <b>233</b><br />
<br />
<b>Fatal error</b>: Call to undefined function read_config_option() in <b>/usr/share/cacti/site/plugins/weathermap/setup.php</b> on line <b>235</b><br />
Code: Select all
/usr/bin/curl http://localhost/cacti/plugins/weathermap/weathermap-cacti-plugin-mgmt.php?action=rebuildnow
Code: Select all
<html>
<head>
<title>Login to Cacti</title>
<STYLE TYPE="text/css">
<!--
BODY, TABLE, TR, TD {font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 12px;}
A {text-decoration: none;}
A:active { text-decoration: none;}
A:hover {text-decoration: underline; color: #333333;}
A:visited {color: Blue;}
-->
</style>
</head>
<body bgcolor="#FFFFFF" onload="document.login.login_username.focus()">
<form name="login" method="post" action="weathermap-cacti-plugin-mgmt.php">
<input type="hidden" name="action" value="login">
<table align="center">
<tr>
<td colspan="2"><center><img src="/images/auth_login.gif" border="0" alt=""></center></td>
</tr>
<tr height="10"><td></td></tr>
<tr>
<td colspan="2">Please enter your Cacti user name and password below:</td>
</tr>
<tr height="10"><td></td></tr>
<tr>
<td>User Name:</td>
<td><input type="text" name="login_username" size="40" style="width: 295px;" value=""></td>
</tr>
<tr>
<td>Password:</td>
<td><input type="password" name="login_password" size="40" style="width: 295px;"></td>
</tr>
<tr height="10"><td></td></tr>
<tr>
<td><input type="submit" value="Login"></td>
</tr>
</table>
</form>
</body>
</html>
Edit : I am wrong, even with the poller, the value are correct, but the drawing doesn't work
Lauched by the button
Launched by the poller
Trying to find some difference between this two method....Something should be wrong somewhere.[/code]
Lauched by the button
Code: Select all
11/19/2009 10:53:17 AM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:359] [Map 1] oc3-fr-dc-01.conf: RRD ReadData: traditional style
11/19/2009 10:53:17 AM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:399] [Map 1] oc3-fr-dc-01.conf: RRD ReadData: Running: /usr/bin/rrdtool fetch /usr/share/cacti/site/rra/core1_traffic_in_801.rrd AVERAGE --start now-800 --end now
11/19/2009 10:53:17 AM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:419] [Map 1] oc3-fr-dc-01.conf: > 1258623600: 4.6610777732e+05 2.6843193810e+03
11/19/2009 10:53:17 AM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:419] [Map 1] oc3-fr-dc-01.conf: > 1258623900: 4.6610777732e+05 2.6843193810e+03
11/19/2009 10:53:17 AM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:419] [Map 1] oc3-fr-dc-01.conf: > 1258624200: 4.7161814747e+05 2.6998169046e+03
11/19/2009 10:53:17 AM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:419] [Map 1] oc3-fr-dc-01.conf: > 1258624500: nan nan
11/19/2009 10:53:17 AM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:419] [Map 1] oc3-fr-dc-01.conf: >
11/19/2009 10:53:17 AM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:427] [Map 1] oc3-fr-dc-01.conf: RRD ReadData: Read 5 lines from rrdtool
11/19/2009 10:53:17 AM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:428] [Map 1] oc3-fr-dc-01.conf: RRD ReadData: Headings are: traffic_in traffic_out
11/19/2009 10:53:17 AM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:437] [Map 1] oc3-fr-dc-01.conf: --
11/19/2009 10:53:17 AM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:437] [Map 1] oc3-fr-dc-01.conf: --1258624500: nan nan
11/19/2009 10:53:17 AM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:437] [Map 1] oc3-fr-dc-01.conf: --1258624200: 4.7161814747e+05 2.6998169046e+03
11/19/2009 10:53:17 AM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:458] [Map 1] oc3-fr-dc-01.conf: 4.7161814747e+05 is OK value for traffic_in
11/19/2009 10:53:17 AM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:458] [Map 1] oc3-fr-dc-01.conf: 2.6998169046e+03 is OK value for traffic_out
Code: Select all
11/19/2009 10:55:52 AM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:492] [Map 1] oc3-fr-dc-01.conf: RRD ReadDataFromRealRRD: Returning (4,5630702333e+05,2,2208223333e+03,1258624500)
11/19/2009 10:55:52 AM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:458] [Map 1] oc3-fr-dc-01.conf: 2,2208223333e+03 is OK value for traffic_out
11/19/2009 10:55:52 AM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:458] [Map 1] oc3-fr-dc-01.conf: 4,5630702333e+05 is OK value for traffic_in
11/19/2009 10:55:52 AM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:437] [Map 1] oc3-fr-dc-01.conf: --1258624500: 4,5630702333e+05 2,2208223333e+03
11/19/2009 10:55:52 AM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:437] [Map 1] oc3-fr-dc-01.conf: --1258624800: nan nan
11/19/2009 10:55:52 AM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:437] [Map 1] oc3-fr-dc-01.conf: --
11/19/2009 10:55:52 AM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:428] [Map 1] oc3-fr-dc-01.conf: RRD ReadData: Headings are: traffic_in traffic_out
11/19/2009 10:55:52 AM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:427] [Map 1] oc3-fr-dc-01.conf: RRD ReadData: Read 5 lines from rrdtool
11/19/2009 10:55:52 AM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:419] [Map 1] oc3-fr-dc-01.conf: >
11/19/2009 10:55:52 AM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:419] [Map 1] oc3-fr-dc-01.conf: > 1258624800: nan nan
11/19/2009 10:55:52 AM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:419] [Map 1] oc3-fr-dc-01.conf: > 1258624500: 4,5630702333e+05 2,2208223333e+03
11/19/2009 10:55:52 AM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:419] [Map 1] oc3-fr-dc-01.conf: > 1258624200: 4,7161814747e+05 2,6998169046e+03
11/19/2009 10:55:52 AM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:419] [Map 1] oc3-fr-dc-01.conf: > 1258623900: 4,6610777732e+05 2,6843193810e+03
11/19/2009 10:55:52 AM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:399] [Map 1] oc3-fr-dc-01.conf: RRD ReadData: Running: /usr/bin/rrdtool fetch /usr/share/cacti/site/rra/core1_traffic_in_801.rrd AVERAGE
You need to edit your file weathermap-cacti-rebuild.php in the weathermap directory. In the file you need to set the correct $cacti_base according to your installation.
Mine is:
You probably can't see any difference in the output between CLI and GUI. At least I couldn't.
Mine is:
Code: Select all
$cacti_base = "/usr/share/cacti/site/";
I found one !
I got it... It's not the library... but... Check the value return, major difference between the button, and the poller :
Launched by the poller
I got it... It's not the library... but... Check the value return, major difference between the button, and the poller :
Launched by the poller
And here, launched by the button :11/19/2009 11:05:58 AM - WEATHERMAP: Poller[0] DEBUG: [ReadData@Weathermap.class.php:837] [Map 1] oc3-fr-dc-01.conf: ReadData complete for LINK CORE-1-AS3215: 40 16
11/19/2009 11:05:58 AM - WEATHERMAP: Poller[0] DEBUG: [ReadData@Weathermap.class.php:831] [Map 1] oc3-fr-dc-01.conf: DataTime MINMAX: 1258625100 -> 1258625100
11/19/2009 11:05:58 AM - WEATHERMAP: Poller[0] DEBUG: [ReadData@Weathermap.class.php:824] [Map 1] oc3-fr-dc-01.conf: Aggregate so far: 40 16
11/19/2009 11:05:58 AM - WEATHERMAP: Poller[0] DEBUG: [ReadData@WeatherMapDataSource_rrd.php:641] [Map 1] oc3-fr-dc-01.conf: RRD ReadData: Returning (40,16,1258625100)
11/19/2009 11:05:58 AM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:492] [Map 1] oc3-fr-dc-01.conf: RRD ReadDataFromRealRRD: Returning (5,3692278713e+05,2,5834688116e+06,1258625100)
What does that mean ?11/19/2009 10:53:17 AM - WEATHERMAP: Poller[0] DEBUG: [ReadData@WeatherMapDataSource_rrd.php:641] [Map 1] oc3-fr-dc-01.conf: RRD ReadData: Returning (5023491.36792,16691471.208,1258624200)
11/19/2009 10:53:17 AM - WEATHERMAP: Poller[0] DEBUG: [ReadData@Weathermap.class.php:824] [Map 1] oc3-fr-dc-01.conf: Aggregate so far: 5023491.36792 16691471.208
11/19/2009 10:53:17 AM - WEATHERMAP: Poller[0] DEBUG: [ReadData@Weathermap.class.php:831] [Map 1] oc3-fr-dc-01.conf: DataTime MINMAX: 1258624200 -> 1258624200
11/19/2009 10:53:17 AM - WEATHERMAP: Poller[0] DEBUG: [ReadData@Weathermap.class.php:837] [Map 1] oc3-fr-dc-01.conf: ReadData complete for LINK CORE-1-AS3215: 5023491.36792 16691471.208
Ok it's working now !Tommy_dk wrote:You need to edit your file weathermap-cacti-rebuild.php in the weathermap directory. In the file you need to set the correct $cacti_base according to your installation.
Mine is:You probably can't see any difference in the output between CLI and GUI. At least I couldn't.Code: Select all
$cacti_base = "/usr/share/cacti/site/";
Thks for your help....
But, I will search around this problem....
- Howie
- Cacti Guru User
- Posts: 5508
- Joined: Thu Sep 16, 2004 5:53 am
- Location: United Kingdom
- Contact:
This sounds like you just need to check the cacti.log - if it's not collecting data, you'll be getting errors about that of some kind.Tommy_dk wrote:Actually I don't have an answer to my own question .... 'cause I really don't know why Debian won't draw all the right link colors and other nifty things in my Weathermaps when it is not being updated from the web gui.
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!)
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!)
- Howie
- Cacti Guru User
- Posts: 5508
- Joined: Thu Sep 16, 2004 5:53 am
- Location: United Kingdom
- Contact:
And neither colour the link? Could you paste the config for one of those links please?Tommy_dk wrote:I get the same output when run from GUI and CLI. As i can see they both collect the data from the rrd-files correct.Howie wrote:This sounds like you just need to check the cacti.log - if it's not collecting data, you'll be getting errors about that of some kind.
/Tommy
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!)
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!)
Who is online
Users browsing this forum: No registered users and 1 guest