Weather via wxer.pl - Weather conditions

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

Moderators: Developers, Moderators

User avatar
Wernicke
Cacti User
Posts: 61
Joined: Tue Jun 08, 2004 3:07 am
Location: Bodø, Norway
Contact:

Post by Wernicke »

yeah, I got exact same problem,
im running redhat though

-Sigurd
User avatar
Wernicke
Cacti User
Posts: 61
Joined: Tue Jun 08, 2004 3:07 am
Location: Bodø, Norway
Contact:

Post by Wernicke »

Yeah, it works with a dummy host.. So i guess the poller would not schedule a poll on a graph without a host.. has to be a bug

-Sigurd
User avatar
TheWitness
Developer
Posts: 16997
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Post by TheWitness »

Actually, non-host data sources work with cmd.php, but not currently with cactid. I have arelease of Cactid (0.8.6e) almost ready that corrects this deficiency. In fact, we released it yesterday, but withdrew it because of an issue that we thought that was resolved that wasn't. The existing malody only applies to the Windoz environment.

Therefore, if you guys want to test in Unix/Linux, just let me know and I will make the file available to you for testing. I could use the help.

TheWitness
True understanding begins only when we realize how little we truly understand...

Life is an adventure, let yours begin with Cacti!

Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages


For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
User avatar
TheWitness
Developer
Posts: 16997
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Post by TheWitness »

Roddie,

You can either download BRANCH_086 or I can send you an e-mail. Pick your poison.

Larry
True understanding begins only when we realize how little we truly understand...

Life is an adventure, let yours begin with Cacti!

Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages


For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
User avatar
TheWitness
Developer
Posts: 16997
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Post by TheWitness »

Yes!

Larry
True understanding begins only when we realize how little we truly understand...

Life is an adventure, let yours begin with Cacti!

Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages


For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
User avatar
TheWitness
Developer
Posts: 16997
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Post by TheWitness »

Lack of sleep will do it every time (me that is).

Larry
True understanding begins only when we realize how little we truly understand...

Life is an adventure, let yours begin with Cacti!

Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages


For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
Hoffswell
Posts: 26
Joined: Fri Jan 07, 2005 10:28 am

Post by Hoffswell »

Hi Everyone -

I'm glad some of you got things going. Like I said, I'm new to the template thing. I see that was definately a problem.

Is it possible that someone could post updated templates that work?

Regarding Weather::Underground perl.

Yes, I should have mentioned that! In order to get the script running, you must have the Weather::Underground perl package installed. Here is the best way I know to install a Perl package:

Code: Select all

linuxbox:~ # perl -MCPAN -e shell

cpan> install Weather::Underground
- Pete
User avatar
Wernicke
Cacti User
Posts: 61
Joined: Tue Jun 08, 2004 3:07 am
Location: Bodø, Norway
Contact:

Post by Wernicke »

The only thing i changed in the template was the tags in <site>
-
Roddie: My graphs started updating when I actualy made a host( It could not be a dummy host with snmp disabled)

Now it's working perfect.(Except Wind Chill witch is still nan)
Im sorry I can't test the experimental cactid, since this is a production server, but it sounds like it works fine

-Sigurd
Hoffswell
Posts: 26
Joined: Fri Jan 07, 2005 10:28 am

negative values

Post by Hoffswell »

windchill works, but in my version of cacti 0.8.6.c, does not do negative values. If I am not mistaken, this has been fixed in 0.8.6d
- Pete
User avatar
Wernicke
Cacti User
Posts: 61
Joined: Tue Jun 08, 2004 3:07 am
Location: Bodø, Norway
Contact:

Post by Wernicke »

heh, I need those negative values.. I live in a cold country
User avatar
TheWitness
Developer
Posts: 16997
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Post by TheWitness »

Check for patches in the patches link.

TheWitness
True understanding begins only when we realize how little we truly understand...

Life is an adventure, let yours begin with Cacti!

Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages


For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
frippe
Posts: 19
Joined: Wed Dec 08, 2004 4:41 am

Post by frippe »

Negative values works for me, I just had to set minimum values in the data template. On the RRDs already created I used "rrdtool tune" to set minimum values for wx_temp and wx_windchill.
User avatar
Wernicke
Cacti User
Posts: 61
Joined: Tue Jun 08, 2004 3:07 am
Location: Bodø, Norway
Contact:

Post by Wernicke »

Everyting has worked perfect the last week, but suddenly the wxer script won't return the wx_wind_chill_f variable

Strange


[root@mrtg scripts]# ./wxer.pl BODO
wx_temp_f:4 wx_wind_speed:35 wx_pressure:29.59 wx_humidity:56 wx_wind_chill_f:


-Sigurd
frippe
Posts: 19
Joined: Wed Dec 08, 2004 4:41 am

Post by frippe »

I don't know the answer to your question Sigurd, However be observant that the script returns the wind speed in km/h instead of mph for Bodo, I altered my script so it translates the speed to m/s regardless if returned in mph or km/h.

This is the code snippet:

Code: Select all

   $wx_wind_speed = $arrayref->[0]->{wind};
   $wx_wind_speed =~ s/ .*//;
   if ($arrayref->[0]->{wind}=~ /mph/){
      $wx_wind_speed = $wx_wind_speed*0.447;
   } else {
      $wx_wind_speed = $wx_wind_speed*0.278;
   }
If you want it to return value in mph do:

Code: Select all

   $wx_wind_speed = $arrayref->[0]->{wind};
   $wx_wind_speed =~ s/ .*//;
   if ($arrayref->[0]->{wind}=~ /mph/){
   } else {
      $wx_wind_speed = $wx_wind_speed/1.61;
   }
User avatar
hbokh
Posts: 40
Joined: Thu Feb 24, 2005 4:29 pm
Location: Groningen, NL

Importing templates not working

Post by hbokh »

Importing the templates "works" after changing <site> into |site|, but nothing happens.
The templates won't show up... it looks like they are not even stored.

Oh... and how to look up the zip for a town? "Eelde, Netherlands" is zip 06280 on "wunderground", but

Code: Select all

wxer.pl 06280
gives different data compared to

Code: Select all

wxer.pl Eelde, Netherlands
:o

FYI:
FreeBSD 4-11-RELEASE
cacti-0.8.6b (from FreeBSD-ports)
php4-4.3.10
mysql-server-4.0.23a
apache-2.0.53
net-snmp-5.2.1
Post Reply

Who is online

Users browsing this forum: No registered users and 3 guests