Windows Ping Script!

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

Moderators: Moderators, Developers

Author
Message
a2line59
Posts: 45
Joined: Mon May 23, 2005 8:20 am
Location: France

#31 Post by a2line59 » Thu Jul 21, 2005 11:14 am

and install 0.8.6f is not a problem ? if i use 0.8.6f, do i loose all graphs ?
what is the best solution to change cacti's version ?

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

#32 Post by TheWitness » Thu Jul 21, 2005 1:12 pm

Oops! I that's odd. I will have to review the ping.php code for divide by zero issues.
True understanding begins only when we realize how little we truly understand...

Life is an adventure, let yours begin with Cacti!

Author of MacTrack, Boost, CLog, SpikeKill, Platform RTM, DSStats, maintainer of Spine, lot's of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Central Plugin Repository
Central Templates Repository


I'm still out there people. Getting excited for Cacti 1.2. I think it will be a great release.

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

#33 Post by TheWitness » Thu Jul 21, 2005 1:14 pm

The upgrade should be uneventful.
True understanding begins only when we realize how little we truly understand...

Life is an adventure, let yours begin with Cacti!

Author of MacTrack, Boost, CLog, SpikeKill, Platform RTM, DSStats, maintainer of Spine, lot's of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Central Plugin Repository
Central Templates Repository


I'm still out there people. Getting excited for Cacti 1.2. I think it will be a great release.

jas0420
Cacti User
Posts: 91
Joined: Thu Jan 13, 2005 3:58 pm
Location: College Station, TX - USA

#34 Post by jas0420 » Thu Jul 21, 2005 1:17 pm

Well, but that was with me running the script in a funky way (just trying to match what was on the Input String since I didn't quite grasp why there were two instances of ss_tping in said string). I don't think it was actually pinging the host. Think that from the command line when I did it like that it was trying to ping something it thought should be called "ss_tping".

So I blame me for that, not your code. :)

jas0420
Cacti User
Posts: 91
Joined: Thu Jan 13, 2005 3:58 pm
Location: College Station, TX - USA

#35 Post by jas0420 » Thu Jul 21, 2005 2:03 pm

I started some new charts with a new Data Input Method, host template, etc. that point to your script so that I could run it in parallel with the tping one. I've only added 4 of the 22 hosts, but so far they have all been accurate this time around. Going to start adding in the rest.......

jas

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

#36 Post by TheWitness » Thu Jul 21, 2005 3:46 pm

Ok,

Here is a modified ss_tping.php. I did in fact screw up for a host that was 100% down. This is what happens when you have a regular job and then do Cacti in your spare time :)

TheWitness

EDIT: I have made another small change and uploaded. The change makes percentage in units such as 5%, 10% instead of 0.05, 0.10 (percent only included in this post). In addition I have limited the results to 4 decimal places.

EDIT2: I have made another small change and uploaded. This last change allows you to specify the number or attempts to make. The timeout still remains with the hosts.

The new syntax is as follows: "php ss_tping hostname [ping_sweeps]". Of course, [ping_sweeps] is optional and if it were the script_server, your poller cache would look as follows:

<cacti_root>/scripts/ss_tping.php ss_tping hostname [ping_sweeps]

TheWitness
Attachments
ss_tping.zip
(683 Bytes) Downloaded 1232 times
True understanding begins only when we realize how little we truly understand...

Life is an adventure, let yours begin with Cacti!

Author of MacTrack, Boost, CLog, SpikeKill, Platform RTM, DSStats, maintainer of Spine, lot's of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Central Plugin Repository
Central Templates Repository


I'm still out there people. Getting excited for Cacti 1.2. I think it will be a great release.

jas0420
Cacti User
Posts: 91
Joined: Thu Jan 13, 2005 3:58 pm
Location: College Station, TX - USA

#37 Post by jas0420 » Thu Jul 21, 2005 4:05 pm

That's really what I was testing when I was filling out the funky script w/bogus hostname... ;)

I wound up starting all of the charts again from scratch... Seems much happier now than this morning when I was tagging it onto the end of the existing charts for some reason...

How about that question above about TheWitness' wishlist?

Thanks for all of the time,
Jason

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

#38 Post by TheWitness » Thu Jul 21, 2005 4:16 pm

I think that I am out of control :)

TheWitness

http://forums.cacti.net/viewtopic.php?p=37589#37589
True understanding begins only when we realize how little we truly understand...

Life is an adventure, let yours begin with Cacti!

Author of MacTrack, Boost, CLog, SpikeKill, Platform RTM, DSStats, maintainer of Spine, lot's of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Central Plugin Repository
Central Templates Repository


I'm still out there people. Getting excited for Cacti 1.2. I think it will be a great release.

jas0420
Cacti User
Posts: 91
Joined: Thu Jan 13, 2005 3:58 pm
Location: College Station, TX - USA

#39 Post by jas0420 » Thu Jul 21, 2005 4:57 pm

Heh... well... the world does revolve around pings, ya know....

I'm afraid I spoke too soon on my success after rebuilding the graphs. Everything went belly up on me again, and it happend after all of them had been going for a while. I had 6 stop charting again, and similar impossible numbers across the WAN.

I can't explain the ones that stopped charting completely, but I'm wondering if somehow the threads are picking up on another thread's reply or something... Once the change happens, it is so consistent though... I'm pretty sure I was away from my desk being umm... a "Notworking" Engineer at the time (slightly before 16:00) the change happened...

Image
Image
Image

Jason

opiekelly
Posts: 1
Joined: Tue Nov 22, 2005 12:26 pm

times are incorrect in grap

#40 Post by opiekelly » Tue Nov 22, 2005 12:36 pm

I am running the following on win2000
cacti 0.8.6g
php 5.0.5
mysql 4.0.26
rrdtool 1.2.11

When the average ping times are less then 1 ms the graphs show 10 times the value. I have average times of 0.31ms which is what is returned from the ss_tping.php script(cacti.log). The graph is showing 310ms. I can run the scipt manually and get 0.31ms response times. Any suggestions.

Thanks
Brendan
Attachments
ping.JPG
ping.JPG (23.01 KiB) Viewed 19083 times

jolramospr
Posts: 32
Joined: Mon Aug 07, 2006 2:32 pm
Location: PR
Contact:

#41 Post by jolramospr » Tue Aug 08, 2006 4:47 pm

I have installed the smokepinglike script but i get the following message on the log:

08/08/2006 05:45:05 PM - CACTID: Poller[0] Host[7] ERROR: Empty result [192.168.28.253]: 'perl /var/www/html/scripts/ping-latency.pl 192.168.28.253'
08/08/2006 05:45:05 PM - CACTID: Poller[0] Host[7] DS[212] WARNING: Result from SCRIPT not valid. Partial Result: ...

User avatar
BSOD2600
Cacti Moderator
Posts: 12160
Joined: Sat May 08, 2004 12:44 pm
Location: USA

#42 Post by BSOD2600 » Tue Aug 08, 2006 5:59 pm

I suggest you use the advanced ping template: http://forums.cacti.net/viewtopic.php?t=10049

As for the error, when you manually run the script, does it return data?

pannes
Posts: 1
Joined: Wed Apr 30, 2008 3:10 am
Location: Sweden, Jönköping

Problem importing xml template

#43 Post by pannes » Wed Apr 30, 2008 3:20 am

Hi
I've tried to import the xml template on my cactiserver running
windows 2003
cact 0.8.7b
IIS6
PHP4
MySQL 4

When I try to import it I end up with the following error:

Code: Select all

Warning: filesize() [function.filesize]: Stat failed for C:\WINDOWS\TEMP\phpC47A.tmp (errno=2 - No such file or directory) in c:\inetpub\wwwroot\cacti\templates_import.php on line 57

Warning: fread() [function.fread]: Length parameter must be greater than 0. in c:\inetpub\wwwroot\cacti\templates_import.php on line 57

Warning: Cannot modify header information - headers already sent by (output started at c:\inetpub\wwwroot\cacti\templates_import.php:57) in c:\inetpub\wwwroot\cacti\templates_import.php on line 75
I figured it was something with the permissions on the temp dir but I've added write,modify,read,list to the IIS user (IIS_WPG). Still no luck.

Would appreciate some input on this, pretty new to iis.

Post Reply