EDIT: Advanced Ping Template Version 1.3 for Cacti 0.8.6g

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

Moderators: Moderators, Developers

Post Reply
Author
Message
ixtab
Posts: 25
Joined: Fri Aug 04, 2006 10:00 am

Re: I get nan data

#196 Post by ixtab » Mon Aug 28, 2006 2:59 pm

i got the same problem when i install advenced ping, i'm working on CentOS and Cacti 0.86h, so if you cant tell what did you do to resolve your problem i will thanks i lot of...
foxtratz wrote:Hi Lvm,

I am using cacti0.8.6h, I only imported the advanced ping template since the ss_fping.php and ping.php already exists in the cacti directory. Im wondering why I am getting nan values or my graph is only red. I tried manually the ss_fping.php script using script server and the result is good. However when I used rrdtool fetch on the database all I can see is nan. Anybody has any idea here? or Do I have to overwrite the existing ss_fping.php or ping.php with the ones you posted.

Thanks and Good Day

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

#197 Post by jolramospr » Tue Sep 12, 2006 3:43 pm

Whe hosts are down i am not receiving any value on the graphs. It just shows a white gap.

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

#198 Post by jolramospr » Tue Sep 12, 2006 3:44 pm

SORRY FOR THE TYPO ABOVE!!!

When hosts are down i am not receiving any value on the graphs. It just shows a white gap.

bltst2
Posts: 4
Joined: Tue Sep 12, 2006 3:54 pm

Class Net_Ping Not Found

#199 Post by bltst2 » Tue Sep 12, 2006 3:57 pm

Everything appears to be in order, but getting the following error on this script:

[[email protected] cacti]# php /var/lib/cacti/scripts/ss_fping.php www.google.com 20
PHP Fatal error: Class 'Net_Ping' not found in /var/lib/cacti/scripts/ss_fping.php on line 25

Net_Ping is installed:
[[email protected] cacti]# pear list
Installed packages, channel pear.php.net:
=========================================
Package Version State
Archive_Tar 1.3.1 stable
Console_Getopt 1.2 stable
Math_Stats 0.8.5 stable
Net_Ping 2.4.1 stable
PEAR 1.4.11 stable
XML_RPC 1.5.0 stable


Any idea what the problem is?

User avatar
eddy
Posts: 32
Joined: Wed Apr 03, 2002 8:48 am
Location: Mississauga, Ontario

ping packet data length

#200 Post by eddy » Tue Sep 19, 2006 3:36 pm

Witness thanks for a new and improved ping tool :D I have one question / request. Would it be possible to specify the length of the ping packet. Something like microsoft allows with the -l variable, like this :

ping 1.1.1.1 -length 1500

so that a user could "emulate" a standard ethernet packet.

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

#201 Post by TheWitness » Tue Sep 19, 2006 11:12 pm

Well, it's entirely possible, but it's not high on my list of priorities and currently the php based ping library is not written for it. So, since that is a "base"/"core" module, it may not happen for a while.

TheWitness
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.

echelon360
Posts: 24
Joined: Tue Mar 28, 2006 2:40 am

Ping Multiple IPs

#202 Post by echelon360 » Tue Oct 10, 2006 12:15 am

Kindly advice:

does the ping utility give me the option to ping several IPs at one go.

For example i have Router A, and i want it to ping the Router B C and D

And lets say from Router G, i only want it to ping a particular server

Can this be setup using the advanced ping utility?

pikes
Posts: 12
Joined: Fri Jun 30, 2006 2:14 pm

#203 Post by pikes » Thu Oct 12, 2006 8:44 am

jolramospr wrote:Whe hosts are down i am not receiving any value on the graphs. It just shows a white gap.
does anyone know if this is fixed in 0.8.6i?

kevandju
Posts: 44
Joined: Tue Oct 10, 2006 3:30 pm

Can't get it to work

#204 Post by kevandju » Tue Oct 17, 2006 10:40 am

Any idean on what I'm doing wrong here or what I need to change? I've tried running from the web interface with no success and no success from command line either.

[[email protected] ~]# php /var/www/html/script_server.php
PHP Script Server has Started - Parent is cmd
ss_fping 10.1.1.2 20 ICMP
WARNING: Function does not exist



Here is my setup
Cacti Version - 0.8.6i
Plugin Architecture - 1.0
Poller Type - Cactid v0.8.6i
Server Info - Linux 2.6.9-42.0.3.EL
Web Server - Apache/2.0.52 (CentOS)
PHP - 4.3.9
PHP Extensions - yp, xml, wddx, tokenizer, sysvshm, sysvsem, standard, sockets, shmop, session, pspell, posix, pcre, overload, mime_magic, iconv, gmp, gettext, ftp, exif, dio, dbx, dba, curl, ctype, calendar, bz2, bcmath, zlib, openssl, apache2handler, gd, mysql, snmp, eAccelerator
MySQL - 4.1.20
RRDTool - 1.2.15
SNMP - 5.1.2
Plugins
  • PHP Network Weathermap (weathermap - v0.82)
    Thresholds (thold - v0.3.0)
    Device Monitoring (monitor - v0.7)
    Network Discovery (discovery - v0.6)
    Network Tools (tools - v0.2)
    Syslog Monitoring (haloe - v0.4)
    mactrack
    RRD Cleaner (rrdclean - v1.1)
    Update Checker (update - v0.3)
    FlowView (flowview - v0.3)
    Host Info (hostinfo - v0.1)
    Error Images (errorimage - v0.1)

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

#205 Post by TheWitness » Tue Oct 17, 2006 11:01 am

you must include the script path first:

/www/html/cacti/scripts/ss_fping.php ss_fping 10.1.1.2 20 ICMP

So, the syntax is:

script_path function_name_to_call function_parameters

TheWitness
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.

kevandju
Posts: 44
Joined: Tue Oct 10, 2006 3:30 pm

#206 Post by kevandju » Tue Oct 17, 2006 1:32 pm

That works and responds with correct ping values, now when I use the graph on one of my hosts it comes up with 100% no replies. I set it up for 20 tries and ICMP and no response, when I do it from SSH though I get perfect replies.

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

#207 Post by TheWitness » Tue Oct 17, 2006 4:43 pm

Run the poller as root and all will work, otherwise, I believe if you run cactid as setuid, then it should work. ICMP packet's can only be generated as a root ID. You also have the option to use TCP pings to some known "open" port.

TheWitness
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.

kevandju
Posts: 44
Joined: Tue Oct 10, 2006 3:30 pm

#208 Post by kevandju » Wed Oct 18, 2006 8:37 am

I have changed the file and group ownership on <cacti path>/poller.php, <cacti path>/lib/poller.php, <cacti path>/lib/ping.php, and <cacti path>/scripts/ss_fping.php from apache to root. Am I missing something because this still doesn't work for me.

Is there something in Cacti where I tell the Graph to run as root? Sorry for being such a n00b and thanks for your help so far!

wwolkers
Posts: 24
Joined: Thu Sep 14, 2006 6:44 am

#209 Post by wwolkers » Wed Oct 18, 2006 11:35 am

kevandju,

what you changed are the permissions... the poller is run by cron, and to be able to do ICMP it needs to run as root, check your cron setup.

mine is in /etc/cron.d/cacti

*/5 * * * * www-data /usr/share/cacti/site/poller.php >/dev/null 2>/var/log/cacti/poller-error.log

currently running as the www-data user, if I want to do ICMP pings, I need to change that to root :)

kevandju
Posts: 44
Joined: Tue Oct 10, 2006 3:30 pm

#210 Post by kevandju » Wed Oct 18, 2006 2:07 pm

That did it, thanks a bunch!!

Post Reply