Nagios Plugin for Cacti (NPC) Released

General discussion about Plugins for Cacti

Moderators: Developers, Moderators

Post Reply
t3ch
Posts: 3
Joined: Tue Feb 28, 2006 7:03 am
Location: Germany

Post by t3ch »

@Teecee: You have to build it in the sourcetree of nagios.
What gives:
ls ../include
Teecee
Posts: 34
Joined: Tue Feb 28, 2006 1:25 pm

Post by Teecee »

t3ch wrote:@Teecee: You have to build it in the sourcetree of nagios.
What gives:
ls ../include
Please forgive my ignorance. Linux is new to me. By sourcetree do you mean where nagios is install aka /usr/local/nagios? When I do a ls ../include it just brings me back to the prompt.
Last edited by Teecee on Wed Mar 01, 2006 6:09 pm, edited 1 time in total.
Teecee
Posts: 34
Joined: Tue Feb 28, 2006 1:25 pm

Post by Teecee »

I think I am confused about the wording in the readme. I already have nagios 2.0 up and running. I also already have cacti up and running. Do I need to recompile and install nagios with the ncp plugin in the nagios dirctory that I made by extracting the latest nagios build? I have been trying to add this plugin into my existing nagios.
t3ch
Posts: 3
Joined: Tue Feb 28, 2006 7:03 am
Location: Germany

Post by t3ch »

You can try this compiled version. Although from OpenSuse 10, it should work. Put it in the directory "modules" - create if not existent.
You should have: <somewhere>
|
nagios
/ \
plugins modules

Hope this helps...
Attachments
inserter.tar.gz
inserter.o
(22.46 KiB) Downloaded 1725 times
Teecee
Posts: 34
Joined: Tue Feb 28, 2006 1:25 pm

Post by Teecee »

t3ch wrote:You can try this compiled version. Although from OpenSuse 10, it should work. Put it in the directory "modules" - create if not existent.
You should have: <somewhere>
|
nagios
/ \
plugins modules

Hope this helps...
I did that using your inserter. On the readme where it tells me to edit the inserter.c and add in my mysql stuff, wouldnt that not work with your inserter.0 since my password and username will be different? No hosts are showing up in my NPC tab.
Teecee
Posts: 34
Joined: Tue Feb 28, 2006 1:25 pm

Post by Teecee »

I got it working. I was trying to run the installer.c in the running nagios directory. I did not know that the source directory meant where I compiled nagios. All is working now. Thanks.
stinkybob
Posts: 1
Joined: Mon Mar 13, 2006 9:56 am

Solaris 9 and NPC

Post by stinkybob »

I seem to be having all kinds of library problems relating to mysql.

Code: Select all

gcc -g -O2 -Wall -shared -o inserter.o inserter.c -L/usr/lib -L/usr/local/lib -L/usr/local/ssl/lib -L/usr/local/my                                            sql/lib -I../include -I/usr/include -I/usr/local/include -I/usr/local/mysql/include -I/usr/local/ssl/include -lmys                                            qlclient -lz -fPIC
inserter.c: In function `loadconfig':
inserter.c:196: warning: implicit declaration of function `asprintf'
Text relocation remains                         referenced
    against symbol                  offset      in file
<unknown>                           0x0         /usr/local/mysql/lib/libmysqlclient.a(ctype.o)
<unknown>                           0x4         /usr/local/mysql/lib/libmysqlclient.a(ctype.o)
<unknown>                           0x8         /usr/local/mysql/lib/libmysqlclient.a(ctype.o)
<unknown>                           0xc         /usr/local/mysql/lib/libmysqlclient.a(ctype.o)
<unknown>                           0x0         /usr/local/mysql/lib/libmysqlclient.a(default.o)
<unknown>                           0x1c        /usr/local/mysql/lib/libmysqlclient.a(default.o)
strlen                              0x10a8      /usr/local/mysql/lib/libmysqlclient.a(libmysql.o)
strlen                              0x230       /usr/local/mysql/lib/libmysqlclient.a(password.o)
strlen                              0x29c       /usr/local/mysql/lib/libmysqlclient.a(password.o)
strlen                              0x9c8       /usr/local/mysql/lib/libmysqlclient.a(password.o)
strlen                              0xa4c       /usr/local/mysql/lib/libmysqlclient.a(password.o)
strlen                              0x108       /usr/local/mysql/lib/libmysqlclient.a(my_malloc.o)
strlen                              0x44        /usr/local/mysql/lib/libmysqlclient.a(mf_pack.o)
strlen                              0x78        /usr/local/mysql/lib/libmysqlclient.a(mf_pack.o)
strlen                              0xdc        /usr/local/mysql/lib/libmysqlclient.a(mf_pack.o)
strlen                              0x128       /usr/local/mysql/lib/libmysqlclient.a(mf_pack.o)
strlen                              0x220       /usr/local/mysql/lib/libmysqlclient.a(mf_pack.o)
strlen                              0x5ec       /usr/local/mysql/lib/libmysqlclient.a(mf_pack.o)
strlen                              0x67c       /usr/local/mysql/lib/libmysqlclient.a(mf_pack.o)
strlen                              0x7a8       /usr/local/mysql/lib/libmysqlclient.a(mf_pack.o)
strlen                              0x5f0       /usr/local/mysql/lib/libmysqlclient.a(my_alloc.o)
strlen                              0x108       /usr/local/mysql/lib/libmysqlclient.a(mf_format.o)
strlen                              0x114       /usr/local/mysql/lib/libmysqlclient.a(mf_format.o)
strlen                              0xb4        /usr/local/mysql/lib/libmysqlclient.a(mf_loadpath.o)
strlen                              0x124       /usr/local/mysql/lib/libmysqlclient.a(my_once.o)
strlen                              0x1c8       /usr/local/mysql/lib/libmysqlclient.a(my_vsnprintf.o)
strlen                              0x3cc       /usr/local/mysql/lib/libmysqlclient.a(ctype.o)
strlen                              0x80c       /usr/local/mysql/lib/libmysqlclient.a(ctype-utf8.o)
strlen                              0x918       /usr/local/mysql/lib/libmysqlclient.a(ctype-utf8.o)
strlen                              0x7f0       /usr/local/mysql/lib/libmysqlclient.a(ctype-ucs2.o)
strlen                              0x7fc       /usr/local/mysql/lib/libmysqlclient.a(ctype-ucs2.o)
strlen                              0xa28       /usr/local/mysql/lib/libmysqlclient.a(ctype-ucs2.o)
strlen                              0x2410      /usr/local/mysql/lib/libmysqlclient.a(ctype-ucs2.o)
strlen                              0x241c      /usr/local/mysql/lib/libmysqlclient.a(ctype-ucs2.o)
strlen                              0x11bc      /usr/local/mysql/lib/libmysqlclient.a(ctype-uca.o)
strlen                              0x2010      /usr/local/mysql/lib/libmysqlclient.a(client.o)
strlen                              0x201c      /usr/local/mysql/lib/libmysqlclient.a(client.o)
strlen                              0x2028      /usr/local/mysql/lib/libmysqlclient.a(client.o)
strlen                              0x2414      /usr/local/mysql/lib/libmysqlclient.a(client.o)
strlen                              0x27a8      /usr/local/mysql/lib/libmysqlclient.a(client.o)
strlen                              0x3310      /usr/local/mysql/lib/libmysqlclient.a(client.o)
strlen                              0x3354      /usr/local/mysql/lib/libmysqlclient.a(client.o)
strlen                              0xcc        /usr/local/mysql/lib/libmysqlclient.a(default.o)
strlen                              0x120       /usr/local/mysql/lib/libmysqlclient.a(default.o)
strlen                              0x358       /usr/local/mysql/lib/libmysqlclient.a(default.o)
strlen                              0x9cc       /usr/local/mysql/lib/libmysqlclient.a(default.o)
strlen                              0xa70       /usr/local/mysql/lib/libmysqlclient.a(default.o)
strlen                              0xa7c       /usr/local/mysql/lib/libmysqlclient.a(default.o)
strlen                              0xadc       /usr/local/mysql/lib/libmysqlclient.a(default.o)
strlen                              0xc84       /usr/local/mysql/lib/libmysqlclient.a(default.o)
strlen                              0x14        /usr/local/mysql/lib/libmysqlclient.a(ctype-mb.o)
strlen                              0xa4        /usr/local/mysql/lib/libmysqlclient.a(ctype-mb.o)
strlen                              0x20c       /usr/local/mysql/lib/libmysqlclient.a(ctype-mb.o)
mysql_close                         0x11f8      /usr/local/mysql/lib/libmysqlclient.a(libmysql.o)
mysql_close                         0x2684      /usr/local/mysql/lib/libmysqlclient.a(client.o)
mysql_close                         0x272c      /usr/local/mysql/lib/libmysqlclient.a(client.o)
mysql_close                         0x29f4      /usr/local/mysql/lib/libmysqlclient.a(client.o)
mysql_close                         0x2a20      /usr/local/mysql/lib/libmysqlclient.a(client.o)
exit                                0x98        /usr/local/mysql/lib/libmysqlclient.a(my_malloc.o)
exit                                0x30        /usr/local/mysql/lib/libmysqlclient.a(str_alloc.o)
exit                                0xc94       /usr/local/mysql/lib/libmysqlclient.a(client.o)
exit                                0x328       /usr/local/mysql/lib/libmysqlclient.a(default.o)
exit                                0x884       /usr/local/mysql/lib/libmysqlclient.a(default.o)
exit                                0x8a4       /usr/local/mysql/lib/libmysqlclient.a(default.o)
printf                              0x7ac       /usr/local/mysql/lib/libmysqlclient.a(default.o)
printf                              0x7dc       /usr/local/mysql/lib/libmysqlclient.a(default.o)
mysql_real_query                    0x10b4      /usr/local/mysql/lib/libmysqlclient.a(libmysql.o)
mysql_real_query                    0x6994      /usr/local/mysql/lib/libmysqlclient.a(libmysql.o)
mysql_real_query                    0x69bc      /usr/local/mysql/lib/libmysqlclient.a(libmysql.o)
mysql_real_query                    0x69f4      /usr/local/mysql/lib/libmysqlclient.a(libmysql.o)
mysql_real_query                    0x6a14      /usr/local/mysql/lib/libmysqlclient.a(libmysql.o)
mysql_real_query                    0x2424      /usr/local/mysql/lib/libmysqlclient.a(client.o)
mysql_real_query                    0x3364      /usr/local/mysql/lib/libmysqlclient.a(client.o)
malloc                              0x10        /usr/local/mysql/lib/libmysqlclient.a(my_malloc.o)
malloc                              0x94        /usr/local/mysql/lib/libmysqlclient.a(my_once.o)
malloc                              0x14        /usr/local/mysql/lib/libmysqlclient.a(str_alloc.o)
strcat                              0x844       /usr/local/mysql/lib/libmysqlclient.a(mf_pack.o)
strcat                              0xdc        /usr/local/mysql/lib/libmysqlclient.a(mf_loadpath.o)
sprintf                             0xeb4       /usr/local/mysql/lib/libmysqlclient.a(libmysql.o)
sprintf                             0x37d8      /usr/local/mysql/lib/libmysqlclient.a(libmysql.o)
sprintf                             0x3934      /usr/local/mysql/lib/libmysqlclient.a(libmysql.o)
sprintf                             0x4b7c      /usr/local/mysql/lib/libmysqlclient.a(libmysql.o)
sprintf                             0x4bac      /usr/local/mysql/lib/libmysqlclient.a(libmysql.o)
sprintf                             0x5d94      /usr/local/mysql/lib/libmysqlclient.a(libmysql.o)
sprintf                             0x258       /usr/local/mysql/lib/libmysqlclient.a(password.o)
sprintf                             0x6dc       /usr/local/mysql/lib/libmysqlclient.a(password.o)
sprintf                             0x1c0       /usr/local/mysql/lib/libmysqlclient.a(my_init.o)
sprintf                             0x23c       /usr/local/mysql/lib/libmysqlclient.a(my_init.o)
sprintf                             0x290       /usr/local/mysql/lib/libmysqlclient.a(my_init.o)
sprintf                             0x64c       /usr/local/mysql/lib/libmysqlclient.a(ctype.o)
sprintf                             0x568       /usr/local/mysql/lib/libmysqlclient.a(xml.o)
sprintf                             0x6d0       /usr/local/mysql/lib/libmysqlclient.a(xml.o)
sprintf                             0x7dc       /usr/local/mysql/lib/libmysqlclient.a(xml.o)
sprintf                             0x8dc       /usr/local/mysql/lib/libmysqlclient.a(xml.o)
sprintf                             0xa58       /usr/local/mysql/lib/libmysqlclient.a(xml.o)
sprintf                             0xab0       /usr/local/mysql/lib/libmysqlclient.a(xml.o)
sprintf                             0xadc       /usr/local/mysql/lib/libmysqlclient.a(xml.o)
........
(lots more of the same deleted for the sake of brevity)
I'm running Solaris 9 (sparc) with the latest patches, mysql 4.1.18 (i've tried 5.0.18 and it does the same thing. Is there any way to compile the object without needing -lmysqlclient or -lz? Can they be linked after the fact with ld? If so, how would I go about doing that?
jshuron
Posts: 1
Joined: Wed Feb 22, 2006 10:53 am

NPC Web site not available

Post by jshuron »

Went to download the npc plugin, but the website link is not available. Could someone please post the tar.gz file if they have it?

Thanks
slander
Posts: 32
Joined: Thu Mar 16, 2006 12:01 pm

Re: NPC Web site not available

Post by slander »

jshuron wrote:Went to download the npc plugin, but the website link is not available. Could someone please post the tar.gz file if they have it?

Thanks
I am not sure if this is the newest or not, but here it is.
Attachments
npc-0.1.1a.tar.gz
(57.35 KiB) Downloaded 8871 times
wolvverine-pld
Posts: 5
Joined: Wed Mar 29, 2006 3:28 am

Post by wolvverine-pld »

here is patch for include headers : http://cvs.pld-linux.org/cgi-bin/cvsweb ... ders.patch
here is spec file (for PLD) : http://cvs.pld-linux.org/cgi-bin/cvsweb ... n-npc.spec

why homepage is currently unavailable? http://www.divagater.com/npc/
routerboy
Posts: 9
Joined: Thu Jan 12, 2006 7:12 pm

Post by routerboy »

For anyone who is using Fruity RC1 to configure Nagios here is a small patch to add in the broker_module line under Main -> Other :D

Fairly straightforward copy the npc-fruity.patch into your fruity directory (eg. /var/www/html/fruity/) then run

Code: Select all

patch -p0 < npc-fruity.patch
You also need to alter the fruity mysql db. You can do this by hand from within mysql admin

Code: Select all

use database fruity;
alter table nagios_main add column broker_module varchar (255);
or

Code: Select all

mysql -p fruity < npc-fruity-patch.sql
Thanks
routerboy
Attachments
npc-fruity-patch.tar.gz
Fruity RC1 NPC Patch
(615 Bytes) Downloaded 1098 times
julpie
Posts: 15
Joined: Mon Apr 03, 2006 7:43 am
Location: Wuerzburg (Germany)

Post by julpie »

Hi,

Does anyone know why this website http://www.divagater.com/npc/ isn't running ?
Does there exist a mirror ?
knobdy
Cacti User
Posts: 495
Joined: Wed Sep 28, 2005 1:39 pm

Post by knobdy »

Has development of this plugin been abandoned perhaps?
julpie
Posts: 15
Joined: Mon Apr 03, 2006 7:43 am
Location: Wuerzburg (Germany)

Post by julpie »

Hi everyone,

I've just installed NPC plug-in for Nagios. It tooks me four days, but now I'm proud :wink:. Thank you for this great job.

However, there's two things which are not running.
1) serviceGroups.php and hostGroups.php are missing. Are these files in development or did I make somethink wrong (who said again? :P) ?
2) In the documentation we can read: "console -> Devices -> <device>
~ After clicking to edit a device you will see a new field called <Nagios Host Mapping>. " For my localhost, I've just "None". Is that normal ?

Thank you for your help.
User avatar
divagater
Cacti User
Posts: 191
Joined: Wed Nov 17, 2004 5:22 pm
Location: Chapel Hill, NC.
Contact:

Post by divagater »

julpie wrote:Hi,

Does anyone know why this website http://www.divagater.com/npc/ isn't running ?
Does there exist a mirror ?
Hi all. I have been away from these forums for quite a while. I apologize that the site hosting NPC went down. Some one did post NPC to this forum with the following link:

http://forums.cacti.net/download.php?id=5127

That is still the latest release available. NPC has not been abandoned. My production environemnt relies heavily on Cacti and NPC. The little company I worked for was bought buy a very big comapny a few months ago. All my spare time has been involved with integrating our technologies and since NPC worked "good enough" I have not touched it. Thats the problem with 1 man projects :)

I am currently "albeit slowly" working on a big rewrite of NPC to use the ndo2db module written by Ethan Galstad. His module will support all Nagios events and will likely stay up to date with new Nagios features. I am also trying to integrate privilege seperation so hosts or services can be viewed only by people with the appropriate permissions.

I can't promise any time frame on this. If there are any PHP/MySQL folks that are interested in helping speed this along I would be glad to collaborate.

~Billy
Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests