Installation nmidSmokeping PLUGIN

General discussion about Plugins for Cacti

Moderators: Developers, Moderators

Post Reply
gjubin
Posts: 4
Joined: Tue Dec 18, 2007 3:34 am

Installation nmidSmokeping PLUGIN

Post by gjubin »

Hi admin of Cacti,

I don't understand how to install this plugin ?

I downloaded this files (http://redmine.nmid-plugins.de/projects ... ping/files) :

createSmokePingConfig.pl.txt
getSmokePingPath.pl.txt
nmidSmokeping_binary_CGI_script.zip
nmidSmokeping_v0.5.zip
setup_v0.5_no_nmidWeb2_nmidCreatePDF_Support.zip

I unzip file nmidSmokeping_v0.5.zip to /var/www/cacti/plugins/
I look nmidSmokeping plugin on link plugin management.

First Question : What is the four other files ? and where I put this files ?
Attachments
nmid1.png
nmid1.png (26.92 KiB) Viewed 26157 times
User avatar
phalek
Developer
Posts: 2838
Joined: Thu Jan 31, 2008 6:39 am
Location: Kressbronn, Germany
Contact:

Re: Installation nmidSmokeping PLUGIN

Post by phalek »

Hi

I just created an updated version. Version 1.12 does only need one file for the Cacti server and can be installed as a normal pluigin.

You can get version 1.12 from here:
http://blog.network-outsourcing.de/prod ... smokeping/

Just install it and configure it using the nmid settings tab:
Image

Then add your devices to your smokeping setup:
Image

Then, you can check the generated "Target" section for your smokeping config in the /tmp dir:
Image

And finally make sure you do have the realm permission added to your user:
Image



Now, the config in the tmp dir is only the part containing the "target" section of your smokeping config. In my case I just append the content of that file to a "config.header":

Code: Select all

*** General ***

owner    = Peter Random
contact  = some@address.nowhere
mailhost = my.mail.host
sendmail = /usr/lib/sendmail
# NOTE: do not put the Image Cache below cgi-bin
# since all files under cgi-bin will be executed ... this is not
# good for images.
imgcache = /var/www/html/smokeping/cache
imgurl   = cache
datadir  = /data/smokeping-ms/data
piddir  = /data/smokeping-ms/var
cgiurl   = http://cacti.network-outsourcing.de/smokeping/smokeping.cgi
smokemail = /opt/smokeping/etc/smokemail
tmail = /opt/smokeping/etc/tmail
# specify this to get syslog logging
syslogfacility = local0
# each probe is now run in its own process
# disable this to revert to the old behaviour
# concurrentprobes = no

*** Alerts ***
to = alertee@address.somewhere
from = smokealert@company.xy

+someloss
type = loss
# in percent
pattern = >0%,*12*,>0%,*12*,>0%
comment = loss 3 times  in a row

*** Database ***

step     = 300
pings    = 20

# consfn mrhb steps total

AVERAGE  0.5   1  1008
AVERAGE  0.5  12  4320
    MIN  0.5  12  4320
    MAX  0.5  12  4320
AVERAGE  0.5 144   720
    MAX  0.5 144   720
    MIN  0.5 144   720

*** Presentation ***

template = /opt/smokeping/etc/basepage.html

+ charts

menu = Charts
title = The most interesting destinations
++ stddev
sorter = StdDev(entries=>4)
title = Top Standard Deviation
menu = Std Deviation
format = Standard Deviation %f

++ max
sorter = Max(entries=>5)
title = Top Max Roundtrip Time
menu = by Max
format = Max Roundtrip Time %f seconds

++ loss
sorter = Loss(entries=>5)
title = Top Packet Loss
menu = Loss
format = Packets Lost %f

++ median
sorter = Median(entries=>5)
title = Top Median Roundtrip Time
menu = by Median
format = Median RTT %f seconds

+ overview

width = 600
height = 50
range = 10h

+ detail

width = 800
height = 160
unison_tolerance = 2

"Last 3 Hours"    3h
"Last 30 Hours"   30h
"Last 10 Days"    10d
"Last 400 Days"   400d

#+ hierarchies
#++ owner
#title = Host Owner
#++ location
#title = Location

*** Probes ***

+ FPing

binary = /usr/sbin/fping

*** Slaves ***
secrets=/opt/smokeping/etc/smokeping_secrets
+boomer
display_name=boomer
color=0000ff

+slave2
display_name=another
color=00ff00

*** Targets ***

probe = FPing

menu = Top
title = Network Latency Grapher
remark = Welcome to the SmokePing website of xxx Company. \
         Here you will learn all about the latency of our network.

## The content of the smokeping_nmid_spserver1_config.txt file goes here :
hope that helps
Last edited by phalek on Wed Jul 24, 2013 3:39 am, edited 1 time in total.
Greetings,
Phalek
---
Need more help ? Read the Cacti documentation or my new Cacti 1.x Book
Need on-site support ? Look here Cacti Workshop
Need professional Cacti support ? Look here CereusService
---
Plugins : CereusReporting
gjubin
Posts: 4
Joined: Tue Dec 18, 2007 3:34 am

Re: Installation nmidSmokeping PLUGIN

Post by gjubin »

Thanks a lot phalek,

I put nmidsmokping version 1.00 :


My settings tab :



Permission is enable :



What happens when i activate this ? new tab ? I see nothing in graph_view.php ...

I have now a file in tmp dir (smokeping_nmid_spserver1_config.txt). i see Just the target

"In my case I just append the content of that file to a "config.header":" < How i do this ?

Code: Select all

+ Allianz
menu = Allianz
title = Allianz

+ Basan_-_JB
menu = Basan - JB
title = Basan - JB

+ BNI
menu = BNI
title = BNI

+ Carlton
menu = Carlton
title = Carlton

+ Default_Tree
menu = Default Tree
title = Default Tree

+ Diadeis
menu = Diadeis
title = Diadeis

+ Henri_Fraise
menu = Henri Fraise
title = Henri Fraise

+ Infoscrib
menu = Infoscrib
title = Infoscrib

+ STTE
menu = STTE
title = STTE

+ TOTAL
menu = TOTAL
title = TOTAL

++ Siège
menu = Siège
title = Location/Devices in Siège

i installed smokping. (apt-get)
How Cacti collect the graph in smokeping ?
In first, I have to create the graph in smokeping and after with this script createSmokePingConfig.pl, I collect and paste the graph on my cacti ?

Code: Select all

perl createSmokePingConfig.pl 
sh: cannot create /opt/smokeping/etc/config: Directory nonexistent

XML or text declaration not at start of entity at line 2, column 0, byte 1 at /usr/lib/perl5/XML/Parser.pm line 187
In my head, the process is not clear :oops:
Attachments
realm.png
realm.png (35.52 KiB) Viewed 26118 times
settings.png
settings.png (34.12 KiB) Viewed 26118 times
nmid.png
nmid.png (94.79 KiB) Viewed 26118 times
User avatar
phalek
Developer
Posts: 2838
Joined: Thu Jan 31, 2008 6:39 am
Location: Kressbronn, Germany
Contact:

Re: Installation nmidSmokeping PLUGIN

Post by phalek »

as described in the previous post from me, you need to go to the "devices" screen and actually add some devices using the drop down list.

Then, you need to find out where your smokeping config is stored. using apt-get I assume it's somewhere in /etc, maybe there's a dir called "/etc/smokeping" which contains a config file.

Check that file and lok for a target section in there, which you would need to replace with the one from the file in your tmp dir.
Greetings,
Phalek
---
Need more help ? Read the Cacti documentation or my new Cacti 1.x Book
Need on-site support ? Look here Cacti Workshop
Need professional Cacti support ? Look here CereusService
---
Plugins : CereusReporting
yaka2b
Posts: 7
Joined: Thu Aug 11, 2011 1:22 pm

Re: Installation nmidSmokeping PLUGIN

Post by yaka2b »

Platform : Debian Squeeze.

Installed smokeping with apt-get and the nmidSmokeping following directions above, but cannot find the getSmokePingPath.pl.

Is this perl script on your site ?

Regards
User avatar
phalek
Developer
Posts: 2838
Joined: Thu Jan 31, 2008 6:39 am
Location: Kressbronn, Germany
Contact:

Re: Installation nmidSmokeping PLUGIN

Post by phalek »

You do not need that script anymore with version 1.00
Greetings,
Phalek
---
Need more help ? Read the Cacti documentation or my new Cacti 1.x Book
Need on-site support ? Look here Cacti Workshop
Need professional Cacti support ? Look here CereusService
---
Plugins : CereusReporting
jigzden
Posts: 1
Joined: Fri Aug 26, 2011 1:09 am

Re: Installation nmidSmokeping PLUGIN

Post by jigzden »

Hi phalek,

I installed Cacti 0.8.7g and common plugins like Thold, Mactrack, Monitor, etc etc without any issues.

Yesterday I installed NmidSmokePing plugin and NmidReportPDF(Express edition). Both is having some issues. Let's first talk about NmidSmokeping.

It installed well (since it showup correctly in the plugin section of Cacti) however when I add any devices from Cacti Console -- Devices "Add to SmokePing" I got the following error in the Cacti error.log file:

CACTI.LOG File================================================================================================================

root@ubuntu:/usr/lib/php5/20090626+lfs/ioncube# tail -f /var/log/cacti/cacti.log
08/26/2011 03:09:44 PM - CMDPHP: Poller[0] ERROR: SQL Cell Failed!, Error:'1054', SQL:"select nwmgmt_settings from host where id=2"
08/26/2011 03:09:44 PM - CMDPHP: Poller[0] ERROR: A DB Exec Failed!, Error:'1054', SQL:"UPDATE host SET nwmgmt_settings = "" WHERE id=2'
08/26/2011 03:09:44 PM - CMDPHP: Poller[0] ERROR: A DB Exec Failed!, Error:'1064', SQL:"UPDATE host SET nwmgmt_smokeping_server="http://mycacti.local" WHERE id='
08/26/2011 03:09:44 PM - CMDPHP: Poller[0] ERROR: SQL Assoc Failed!, Error:'1054', SQL:"select nwmgmt_smokeping_server,nwmgmt_settings from host where id=1"
08/26/2011 03:09:44 PM - CMDPHP: Poller[0] ERROR: SQL Assoc Failed!, Error:'1054', SQL:"select nwmgmt_smokeping_server,nwmgmt_settings from host where id=2"
08/26/2011 03:09:44 PM - CMDPHP: Poller[0] ERROR: SQL Assoc Failed!, Error:'1054', SQL:"select nwmgmt_smokeping_server,nwmgmt_settings from host where id=8"

APACHE2 ERROR.LOG file ==========================================================================================================
[Fri Aug 26 14:26:15 2011] [error] [client X.X.X.X] PHP Warning: preg_match(): No ending delimiter '/' found in /usr/share/cacti/site/plugins/nmidSmokeping/setup.php on line 113, referer: http://X.X.X.X/cacti/host.php
[Fri Aug 26 14:26:15 2011] [error] [client X.X.X.X] PHP Warning: preg_match(): No ending delimiter '/' found in /usr/share/cacti/site/plugins/nmidSmokeping/setup.php on line 113, referer: http://X.X.X.X/cacti/host.php
[Fri Aug 26 14:26:15 2011] [error] [client X.X.X.X] PHP Warning: preg_match(): No ending delimiter '/' found in /usr/share/cacti/site/plugins/nmidSmokeping/setup.php on line 113, referer: http://X.X.X.X/cacti/host.php
[Fri Aug 26 15:09:44 2011] [error] [client X.X.X.X] PHP Notice: Undefined variable: host_id in /usr/share/cacti/site/plugins/nmidSmokeping/setup.php on line 96, referer: http://X.X.X.X/cacti/host.php
[Fri Aug 26 15:09:44 2011] [error] [client X.X.X.X] PHP Notice: Undefined variable: host_id in /usr/share/cacti/site/plugins/nmidSmokeping/setup.php on line 96, referer: http://X.X.X.X/cacti/host.php
[Fri Aug 26 15:09:44 2011] [error] [client X.X.X.X] PHP Notice: Undefined variable: host_id in /usr/share/cacti/site/plugins/nmidSmokeping/setup.php on line 96, referer: http://X.X.X.X/cacti/host.php

Can you please help to resove the error.

Thanks in Advance,

Jig
User avatar
phalek
Developer
Posts: 2838
Joined: Thu Jan 31, 2008 6:39 am
Location: Kressbronn, Germany
Contact:

Re: Installation nmidSmokeping PLUGIN

Post by phalek »

Yes,

There's an importat step in the setup.php file missing.

Please replace the setup.php file with the attached one, disable/uninstall the plugin and then enable/install it again.

I replaced the original tgz file on the project page with a zip containing this updated setup.php file.
Attachments
setup.zip
(5.09 KiB) Downloaded 707 times
Greetings,
Phalek
---
Need more help ? Read the Cacti documentation or my new Cacti 1.x Book
Need on-site support ? Look here Cacti Workshop
Need professional Cacti support ? Look here CereusService
---
Plugins : CereusReporting
User avatar
zoemu
Cacti User
Posts: 287
Joined: Fri Jul 10, 2009 1:38 pm
Location: Toronto, Canada

Re: Installation nmidSmokeping PLUGIN

Post by zoemu »

hi Phal:

I'm moving my windows cacti to an ubuntu server, I have installed everything but smokeping, i'm having some issues with undefined variables

Code: Select all

[Tue Sep 20 16:35:02 2011] [error] [client 10.1.140.174] PHP Notice:  Undefined index: debug in /usr/share/cacti/site/plugins/nmidSmokeping/getSmokePingImage.php on line 10
[Tue Sep 20 16:35:02 2011] [error] [client 10.1.140.174] PHP Fatal error:  Call to undefined function readConfigOption() in /usr/share/cacti/site/plugins/nmidSmokeping/getSmokePingImage.php on line 17
[Tue Sep 20 16:35:46 2011] [error] [client 10.1.140.174] PHP Notice:  Undefined variable: dhtml_tree in /usr/share/cacti/site/lib/html_tree.php on line 504
[Tue Sep 20 16:35:47 2011] [error] [client 10.1.140.174] PHP Notice:  Undefined index: debug in /usr/share/cacti/site/plugins/nmidSmokeping/getSmokePingImage.php on line 10, referer: http://10.1.140.7/cacti/graph_view.php?action=tree&tree_id=2&leaf_id=16
[Tue Sep 20 16:35:47 2011] [error] [client 10.1.140.174] PHP Fatal error:  Call to undefined function readConfigOption() in /usr/share/cacti/site/plugins/nmidSmokeping/getSmokePingImage.php on line 17, referer: http://10.1.140.7/cacti/graph_view.php?action=tree&tree_id=2&leaf_id=16

please note that my Smokeping install is working great...

thanks

LA
julian924s
Cacti User
Posts: 113
Joined: Thu Mar 13, 2008 3:36 am

Re: Installation nmidSmokeping PLUGIN

Post by julian924s »

Hi Phalek - so how do you view the smokeping graphs via Cacti? I have smokeping working on my Cacti server, I've added your nmidsmokeping v1 plugin and it's all setup correctly and without error. But where in Cacti or what in Cacti am I looking for so I can actually view the graphs??? There's no extra tab and no links by the side of any of my graphs to display these.

Thanks - J.
User avatar
phalek
Developer
Posts: 2838
Joined: Thu Jan 31, 2008 6:39 am
Location: Kressbronn, Germany
Contact:

Re: Installation nmidSmokeping PLUGIN

Post by phalek »

zoemu wrote:hi Phal:

I'm moving my windows cacti to an ubuntu server, I have installed everything but smokeping, i'm having some issues with undefined variables

please note that my Smokeping install is working great...

thanks

LA
Hi Zoemu,

Please download the latest file from here: http://redmine.nmid-plugins.de/projects ... ping/files

It should fix this issue.
Greetings,
Phalek
---
Need more help ? Read the Cacti documentation or my new Cacti 1.x Book
Need on-site support ? Look here Cacti Workshop
Need professional Cacti support ? Look here CereusService
---
Plugins : CereusReporting
User avatar
phalek
Developer
Posts: 2838
Joined: Thu Jan 31, 2008 6:39 am
Location: Kressbronn, Germany
Contact:

Re: Installation nmidSmokeping PLUGIN

Post by phalek »

julian924s wrote:Hi Phalek - so how do you view the smokeping graphs via Cacti? I have smokeping working on my Cacti server, I've added your nmidsmokeping v1 plugin and it's all setup correctly and without error. But where in Cacti or what in Cacti am I looking for so I can actually view the graphs??? There's no extra tab and no links by the side of any of my graphs to display these.

Thanks - J.
What Cacti version do you have Pia 2.8 or Pia 2.9 ?

If you have Pia 2.8 you need to download the html_tree.php replacement for the original cacti file from here:

http://redmine.nmid-plugins.de/projects ... epdf/files
Greetings,
Phalek
---
Need more help ? Read the Cacti documentation or my new Cacti 1.x Book
Need on-site support ? Look here Cacti Workshop
Need professional Cacti support ? Look here CereusService
---
Plugins : CereusReporting
julian924s
Cacti User
Posts: 113
Joined: Thu Mar 13, 2008 3:36 am

Re: Installation nmidSmokeping PLUGIN

Post by julian924s »

Thanks Phalek - apologies yes I'm running:

Cacti Version: 0.8.7g, Plugin Architecture Version: 2.8

I've dropped in the replacement html_tree.php for version 0.8.7g and done a visual check but still don't see anything. Have also disabled, uninstalled, installed, enabled the plugin but no change. I'm still a little unsure as to what exactly I'm looking for in Cacti and where?

Thanks again - J.
User avatar
phalek
Developer
Posts: 2838
Joined: Thu Jan 31, 2008 6:39 am
Location: Kressbronn, Germany
Contact:

Re: Installation nmidSmokeping PLUGIN

Post by phalek »

Greetings,
Phalek
---
Need more help ? Read the Cacti documentation or my new Cacti 1.x Book
Need on-site support ? Look here Cacti Workshop
Need professional Cacti support ? Look here CereusService
---
Plugins : CereusReporting
julian924s
Cacti User
Posts: 113
Joined: Thu Mar 13, 2008 3:36 am

Re: Installation nmidSmokeping PLUGIN

Post by julian924s »

Hi - yes I did, received no errors or warnings. Went through your steps and added the smokeping_nmid_spserver1_config.txt file to my existing smokeping install and did a reload of smokeping just to test. In smokeping itself I can see all the graphs as you would expect.

I just don't see anything in Cacti, links etc.

Thanks.
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest