Network Management Integration Plugin ( v0.3.9a Build 129 )

Announcements concerning Plugins for Cacti

Moderators: Developers, Moderators

Post Reply
Voiper99
Cacti User
Posts: 276
Joined: Thu Mar 01, 2007 5:43 pm
Location: Melbourne, Australia

Post by Voiper99 »

I see. Thanks a lot for the info :)
999s
Posts: 2
Joined: Thu Aug 27, 2009 5:19 am

Post by 999s »

Hi Phalek,

Is there a way to do a mass update to generate new nwmgmt_smokeping_path for all the hosts?

It would be great if you could add preg_replace codes for "[", "]", and "@".
User avatar
phalek
Developer
Posts: 2838
Joined: Thu Jan 31, 2008 6:39 am
Location: Kressbronn, Germany
Contact:

Post by phalek »

For the fix, that should be easy ( i guess you added that already ?)

Code: Select all

$menu_text = preg_replace("@\@@","C",$menu_text);
$menu_text = preg_replace("@\[@","C",$menu_text);
$menu_text = preg_replace("@\]@","C",$menu_text);
but the other thing is a bit more complicated.

You need to get the host ids of you devices and for each of these "host_id" your need to execute the following statements ( change them to fit your system )

Code: Select all

UPDATE host SET nwmgmt_settings = "s1" WHERE id=host_id
UPDATE host SET nwmgmt_smokeping_path="" WHERE id=host_id
UPDATE host SET nwmgmt_smokeping_probe="" WHERE id=host_id
UPDATE host SET nwmgmt_smokeping_server="http://smokepingserver" WHERE id=host_id

nwmgmt_smokeping_server is the value that is displayed in the drop-down list when you go to the "configure devices page".
nwmgmt_smokeping_probe can be left empty
nwmgmt_smokeping_path is only built when you click the "save" button on the confgigure devices page, so you need to do this once you've filled the DB

nwmgmt_settings = s1 measn "Smokeping enabled"
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
999s
Posts: 2
Joined: Thu Aug 27, 2009 5:19 am

Post by 999s »

thanks phalek

Yes I've made the changes to the setup.php for the preg_replace bit.

Where do you recommend to insert the extra lines under lib/html_tree.php for 0.8.7g?

Code: Select all

if (!empty($leaf_id)) {
do_hook_function('tree_after',$host_name.','.get_request_var("leaf_id"));
}
User avatar
phalek
Developer
Posts: 2838
Joined: Thu Jan 31, 2008 6:39 am
Location: Kressbronn, Germany
Contact:

Post by phalek »

you can download the one I already changed from here:

http://redmine.nmid-plugins.de/projects ... epdf/files

either just copy it over, or compare it with a diff to see the changes. :-)
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
ravinald
Posts: 5
Joined: Tue Jan 24, 2006 5:31 pm

nmidPhpip

Post by ravinald »

There is lots of mention of nmidPhpip although the last compatibility matrix for 0.8.7g suggests not only does the base plugin not work but nmidPhpip also does not.

Is there an update I am missing?
User avatar
phalek
Developer
Posts: 2838
Joined: Thu Jan 31, 2008 6:39 am
Location: Kressbronn, Germany
Contact:

Post by phalek »

You do not miss any update. Nmid and the nmidphpip package should work out of the box. Nmid does for sure and a customized nmidphpip package also.
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
ravinald
Posts: 5
Joined: Tue Jan 24, 2006 5:31 pm

Post by ravinald »

phalek wrote:You do not miss any update. Nmid and the nmidphpip package should work out of the box. Nmid does for sure and a customized nmidphpip package also.
I'm unable to find any DL link for nmidphpip form this post or from your web site.
User avatar
phalek
Developer
Posts: 2838
Joined: Thu Jan 31, 2008 6:39 am
Location: Kressbronn, Germany
Contact:

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
artiflo
Cacti User
Posts: 76
Joined: Wed Dec 19, 2007 2:00 pm

Re: Network Management Integration Plugin ( v0.3.9a Build 12

Post by artiflo »

I don't see graph on cacti with nmidsmokeping (but graph works with smokeping).

I have :
Cacti 0.8.7g
PIA : 2.8
Network Management Inventory Database : 0.3.9a
NMID SmokePing Plugin : 0.5
NMID WebService Plugin : 0.7

Setting of my : getSmokePingPath.pl

Code: Select all

### START OF WEB SERVCE SETTINGS ###
my $webservice_password = 'Test123';
my $webservice_url = 'http://xx.xx.xx.xx/cacti/plugins/nmidWebService/webservice.php?wsdl';
my $tmp_dir = '/tmp/';
### END OF WEB SERVCE SETTINGS ###
Each time a try to see smokeping in cacti I have this error :

Code: Select all

[Wed Nov 10 18:27:12 2010] [error] [client xxxxxxxxxx] 500 Can't connect to www.nmid-plugins.de:8080 (Bad hostname 'www.nmid-plugins.de') at /var/www/cgi-bin/getSmokePingPath.pl line 25, referer: http://xxxxxxxx/cacti/graph_view.php?action=tree&tree_id=4&leaf_id=59
[Wed Nov 10 18:27:12 2010] [error] [client xxxxxxx] Premature end of script headers: getSmokePingPath.pl, referer: http://xxxxxx/cacti/graph_view.php?action=tree&tree_id=4&leaf_id=59
Why the webservice try to go to internet ? My cacti server is just on my local network, it can't go to internet.
User avatar
phalek
Developer
Posts: 2838
Joined: Thu Jan 31, 2008 6:39 am
Location: Kressbronn, Germany
Contact:

Re: Network Management Integration Plugin ( v0.3.9a Build 12

Post by phalek »

you need to edit the webservice.wsdl file and change all occurences of www.nmid-plugins.de to your local server.

That should fix it.
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
artiflo
Cacti User
Posts: 76
Joined: Wed Dec 19, 2007 2:00 pm

Re: Network Management Integration Plugin ( v0.3.9a Build 12

Post by artiflo »

phalek wrote:you need to edit the webservice.wsdl file and change all occurences of http://www.nmid-plugins.de to your local server.

That should fix it.
Thanks that works now :)
User avatar
phalek
Developer
Posts: 2838
Joined: Thu Jan 31, 2008 6:39 am
Location: Kressbronn, Germany
Contact:

Re: Network Management Integration Plugin ( v0.3.9a Build 12

Post by phalek »

Update for nmidSmokeping:
I've created a binary file for linux (32bit) in case someone cannot install all pre-reqs for the perl script.
Just use it instead of the perl file as your CGI script. It comes with a .ini file that you need to adapt to your environment.

You can download it from here: nmidSmokeping Project page
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
equick
Cacti User
Posts: 72
Joined: Wed Jun 14, 2006 4:31 am
Contact:

Re: Network Management Integration Plugin ( v0.3.9a Build 12

Post by equick »

artiflo wrote:I don't see graph on cacti with nmidsmokeping (but graph works with smokeping).

I have :
Cacti 0.8.7g
PIA : 2.8
Network Management Inventory Database : 0.3.9a
NMID SmokePing Plugin : 0.5
NMID WebService Plugin : 0.7

Setting of my : getSmokePingPath.pl

Code: Select all

### START OF WEB SERVCE SETTINGS ###
my $webservice_password = 'Test123';
my $webservice_url = 'http://xx.xx.xx.xx/cacti/plugins/nmidWebService/webservice.php?wsdl';
my $tmp_dir = '/tmp/';
### END OF WEB SERVCE SETTINGS ###
Each time a try to see smokeping in cacti I have this error :

Code: Select all

[Wed Nov 10 18:27:12 2010] [error] [client xxxxxxxxxx] 500 Can't connect to www.nmid-plugins.de:8080 (Bad hostname 'www.nmid-plugins.de') at /var/www/cgi-bin/getSmokePingPath.pl line 25, referer: http://xxxxxxxx/cacti/graph_view.php?action=tree&tree_id=4&leaf_id=59
[Wed Nov 10 18:27:12 2010] [error] [client xxxxxxx] Premature end of script headers: getSmokePingPath.pl, referer: http://xxxxxx/cacti/graph_view.php?action=tree&tree_id=4&leaf_id=59
Why the webservice try to go to internet ? My cacti server is just on my local network, it can't go to internet.

Hi,

I'm using the same versions as above and have also configured getSmokePingPath.pl and substituted the url, but I don't see nmid in cacti settings. I do have smokeping set up and working though. Also I am not sure where the following code goes in lib/html_tree.php as the code looks like it may have been updated in 0.8.7g. Is this still a requirement?

Code: Select all

At around line 795:
        if (!empty($leaf_id)) {
                do_hook_function('tree_after',$host_name.','.get_request_var("leaf_id"));
        }
If I call /cgi-bin/getSmokePingPath.pl I get the following in access_log. The POSTs seem to be failing, I'm not sure why, no php errors are being logged.

Code: Select all

192.168.1.23 - - [01/Jan/2011:23:42:57 +0000] "GET /cacti/plugins/nmidWebService/webservice.wsdl HTTP/1.1" 200 21803 "-" "libwww-perl/5.837"
192.168.1.23 - - [01/Jan/2011:23:42:57 +0000] "POST /cacti/plugins/nmidWebService/webservice.php HTTP/1.1" 500 289 "-" "SOAP::Lite/Perl/0.710.10"
192.168.1.23 - - [01/Jan/2011:23:42:57 +0000] "GET /cacti/plugins/nmidWebService/webservice.wsdl HTTP/1.1" 200 21803 "-" "libwww-perl/5.837"
192.168.1.23 - - [01/Jan/2011:23:42:57 +0000] "POST /cacti/plugins/nmidWebService/webservice.php HTTP/1.1" 500 289 "-" "SOAP::Lite/Perl/0.710.10"
192.168.1.23 - - [01/Jan/2011:23:42:57 +0000] "GET /cacti/plugins/nmidWebService/webservice.wsdl HTTP/1.1" 200 21803 "-" "libwww-perl/5.837"
192.168.1.23 - - [01/Jan/2011:23:42:57 +0000] "POST /cacti/plugins/nmidWebService/webservice.php HTTP/1.1" 500 289 "-" "SOAP::Lite/Perl/0.710.10"
87.194.35.94 - - [01/Jan/2011:23:42:57 +0000] "GET /cgi-bin/getSmokePingPath.pl HTTP/1.1" 200 - "-" "Mozilla/5.0 (X11; U; Linux i686; en-US) AppleWebKit/534.10 (KHTML, like Gecko) Chrome/8.0.552.224 Safari/534.10"
Could you possibly give me a few pointers to get me on track please?

Thanks,

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

Re: Network Management Integration Plugin ( v0.3.9a Build 12

Post by phalek »

look into the wsdl file in the nmidWebService dir and replace everything that points to nmid-plugins.de to the url of your Cacti installation.

The hook is still reuired for PIA 2.8, PIA 2.9 does include the hook ( though I need to publish an update for nmidSmokeping to actually use it)
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
Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests