Nagios Plugin for Cacti (NPC) 2.0.4
Moderators: Developers, Moderators
-
- Posts: 33
- Joined: Tue May 05, 2009 7:28 pm
ponwude same prob
Okay glad I am not the only one, it seems that ponwude has the same issue I am having...
-
- Posts: 33
- Joined: Tue May 05, 2009 7:28 pm
Updates
As an update well, I am afraid I am still having the same issue, please can someone help out with this.
Only thing I get in error log is:
[Thu Nov 05 11:18:51 2009] [error] [client XXX] PHP Notice: Undefined index: action in /var/www/html/cacti/plugins/npc/top_graph_header.php on line 95, referer: http://XXX.au/cacti/plugins/npc/npc.php
[Thu Nov 05 11:18:51 2009] [error] [client XXX] PHP Notice: Undefined index: action in /var/www/html/cacti/plugins/npc/top_graph_header.php on line 95, referer: http://XXX.au/cacti/plugins/npc/npc.php
[Thu Nov 05 11:18:51 2009] [error] [client XXX] PHP Notice: Undefined index: action in /var/www/html/cacti/plugins/npc/top_graph_header.php on line 95, referer: http://XXX.au/cacti/plugins/npc/npc.php
But by the looks of it, shouldn't be causing the issue I am having, this seems due just to not having anything to graph...
Please help me out with this guys
Only thing I get in error log is:
[Thu Nov 05 11:18:51 2009] [error] [client XXX] PHP Notice: Undefined index: action in /var/www/html/cacti/plugins/npc/top_graph_header.php on line 95, referer: http://XXX.au/cacti/plugins/npc/npc.php
[Thu Nov 05 11:18:51 2009] [error] [client XXX] PHP Notice: Undefined index: action in /var/www/html/cacti/plugins/npc/top_graph_header.php on line 95, referer: http://XXX.au/cacti/plugins/npc/npc.php
[Thu Nov 05 11:18:51 2009] [error] [client XXX] PHP Notice: Undefined index: action in /var/www/html/cacti/plugins/npc/top_graph_header.php on line 95, referer: http://XXX.au/cacti/plugins/npc/npc.php
But by the looks of it, shouldn't be causing the issue I am having, this seems due just to not having anything to graph...
Please help me out with this guys
Working
Hi All,
My Nagios and NPC is working now. I went back and rechecked all setup lines from the guide. i apparently had a typo somewhere.
I have another question though. do i have to manually enter host information for all the routers i want to monitor in the switch.cfg file??? sounds tideous.
please can someone post an example configuration for a router + services. The example in the guide isn't so explanatory.
thanks
My Nagios and NPC is working now. I went back and rechecked all setup lines from the guide. i apparently had a typo somewhere.
I have another question though. do i have to manually enter host information for all the routers i want to monitor in the switch.cfg file??? sounds tideous.
please can someone post an example configuration for a router + services. The example in the guide isn't so explanatory.
thanks
-
- Posts: 33
- Joined: Tue May 05, 2009 7:28 pm
Good to hear you got things working ponwude,
However, I still have the same fate, after checking and rechecking everything again as per the guide, still nothing....
Have have seemingly done everything, set permissions to 777 on things I had doubt about and still no go...
I wish someone could help me out though...
However, I still have the same fate, after checking and rechecking everything again as per the guide, still nothing....
Have have seemingly done everything, set permissions to 777 on things I had doubt about and still no go...
I wish someone could help me out though...
-
- Posts: 33
- Joined: Tue May 05, 2009 7:28 pm
My current info:
Cacti Version - 0.8.7e
Plugin Architecture - 2.4
Poller Type - Cactid v
Server Info - Linux 2.6.18-128.4.1.el5
Web Server - Apache/2.2.3 (Red Hat)
PHP - 5.2.10
PHP Extensions - date, libxml, openssl, pcre, zlib, bz2, calendar, ctype, session, filter, ftp, gettext, gmp, hash, iconv, mime_magic, Reflection, standard, shmop, SimpleXML, SPL, sockets, exif, tokenizer, xml, apache2handler, curl, dba, dbase, gd, json, ldap, mbstring, mysql, mysqli, odbc, PDO, pdo_mysql, PDO_ODBC, pdo_sqlite, snmp, SQLite, zip
MySQL - 5.1.40
RRDTool - 1.3.6
SNMP - 5.3.2.2
Plugins
- Cacti Log View (CLog - v1.21)
Watermark (watermark - v0.1)
Cycle Graphs (Cycle Graphs - v0.7)
Update Checker (update - v0.4)
Login Page Mod (loginmod - v1.0)
Thresholds (thold - v0.4.1)
Global Plugin Settings (settings - v0.5)
Realtime Graph Viewer (realtime - v0.36)
Host Info (hostinfo - v0.2)
I am having trouble graphing the information from NPC.
The data input method is working:
From the Cacti log:
11/06/2009 12:30:02 PM - CMDPHP: Poller[0] Host[0] DS[644] CMD: php /var/www/cacti/plugins/npc/perfdata.php --type=service --id=264 2> /dev/null, output: designGallery(secs):1.329221
From the command line:
[root@xxx rra]# php /var/www/cacti/plugins/npc/perfdata.php --type=service --id=264 2> /dev/null
designGallery(secs):2.135832
However if I use rrdtool to fetch the rrd:
[root@xxx rra]# rrdtool fetch choosethis_644.rrd AVERAGE
choosethis
1257454200: nan
1257454500: nan
1257454800: nan
1257455100: nan
1257455400: nan
1257455700: nan
1257456000: nan
1257456300: nan
1257456600: nan
1257456900: nan
1257457200: nan
1257457500: nan
1257457800: nan
1257458100: nan
1257458400: nan
It returns all NaNs.
Debugging the rrd shows it is ok.
I have followed this guide: http://www.cacti.net/downloads/docs/html/how_to.html over and over
I would really appreciate any help with this problem.
The data input method is working:
From the Cacti log:
11/06/2009 12:30:02 PM - CMDPHP: Poller[0] Host[0] DS[644] CMD: php /var/www/cacti/plugins/npc/perfdata.php --type=service --id=264 2> /dev/null, output: designGallery(secs):1.329221
From the command line:
[root@xxx rra]# php /var/www/cacti/plugins/npc/perfdata.php --type=service --id=264 2> /dev/null
designGallery(secs):2.135832
However if I use rrdtool to fetch the rrd:
[root@xxx rra]# rrdtool fetch choosethis_644.rrd AVERAGE
choosethis
1257454200: nan
1257454500: nan
1257454800: nan
1257455100: nan
1257455400: nan
1257455700: nan
1257456000: nan
1257456300: nan
1257456600: nan
1257456900: nan
1257457200: nan
1257457500: nan
1257457800: nan
1257458100: nan
1257458400: nan
It returns all NaNs.
Debugging the rrd shows it is ok.
I have followed this guide: http://www.cacti.net/downloads/docs/html/how_to.html over and over
I would really appreciate any help with this problem.
-
- Posts: 33
- Joined: Tue May 05, 2009 7:28 pm
-
- Posts: 33
- Joined: Tue May 05, 2009 7:28 pm
-
- Posts: 10
- Joined: Mon Jul 16, 2007 10:57 am
Portlet Height
Can someone let me know how to increase the height of the portlets, as i am unable to do it through the portlet configuration.
Thanks in advance.
Thanks in advance.
-
- Posts: 33
- Joined: Tue May 05, 2009 7:28 pm
Finally fixed the issue myself.
The SQL doesn't create the needed default columns....
I ran the following to fix the database and actually get somewhere...
ALTER TABLE `npc_hostchecks` ADD COLUMN `long_output` varchar(8192) NOT NULL default '' AFTER `output`;
ALTER TABLE `npc_hoststatus` ADD COLUMN `long_output` varchar(8192) NOT NULL default '' AFTER `output`;
ALTER TABLE `npc_servicechecks` ADD COLUMN `long_output` varchar(8192) NOT NULL default '' AFTER `output`;
ALTER TABLE `npc_servicestatus` ADD COLUMN `long_output` varchar(8192) NOT NULL default '' AFTER `output`;
ALTER TABLE `npc_statehistory` ADD COLUMN `long_output` varchar(8192) NOT NULL default '' AFTER `output`;
ALTER TABLE `npc_eventhandlers` ADD COLUMN `long_output` varchar(8192) NOT NULL default '' AFTER `output`;
ALTER TABLE `npc_systemcommands` ADD COLUMN `long_output` varchar(8192) NOT NULL default '' AFTER `output`;
ALTER TABLE `npc_notifications` ADD COLUMN `long_output` varchar(8192) NOT NULL default '' AFTER `output`;
The SQL doesn't create the needed default columns....
I ran the following to fix the database and actually get somewhere...
ALTER TABLE `npc_hostchecks` ADD COLUMN `long_output` varchar(8192) NOT NULL default '' AFTER `output`;
ALTER TABLE `npc_hoststatus` ADD COLUMN `long_output` varchar(8192) NOT NULL default '' AFTER `output`;
ALTER TABLE `npc_servicechecks` ADD COLUMN `long_output` varchar(8192) NOT NULL default '' AFTER `output`;
ALTER TABLE `npc_servicestatus` ADD COLUMN `long_output` varchar(8192) NOT NULL default '' AFTER `output`;
ALTER TABLE `npc_statehistory` ADD COLUMN `long_output` varchar(8192) NOT NULL default '' AFTER `output`;
ALTER TABLE `npc_eventhandlers` ADD COLUMN `long_output` varchar(8192) NOT NULL default '' AFTER `output`;
ALTER TABLE `npc_systemcommands` ADD COLUMN `long_output` varchar(8192) NOT NULL default '' AFTER `output`;
ALTER TABLE `npc_notifications` ADD COLUMN `long_output` varchar(8192) NOT NULL default '' AFTER `output`;
Performance data and Status information
Hello,
This is a great plugin and it's working ok in my test environment but before going into production I was wondering if it's possible to grab information for the Data Input Method from "Status Information" instead of only "Performance Data". I have several plugins that do not post any information in the Performance Data field, only in the Status Information.
I've been looking through the threads and I haven't read anything about it.
Thanks for your help!
This is a great plugin and it's working ok in my test environment but before going into production I was wondering if it's possible to grab information for the Data Input Method from "Status Information" instead of only "Performance Data". I have several plugins that do not post any information in the Performance Data field, only in the Status Information.
I've been looking through the threads and I haven't read anything about it.
Thanks for your help!
Question
Hello!
I've installed this plugin, but have some quesitons:
I've 3 servers, every server has it own service running:
1.st server for cacti
2.nd server for nagios
3.th server with database and NDO2DB
I've a Nagios server with ND02DB in production that log all the content to an esternal server on MySQL.
1. It's possible to set up cacti NPC to work with an external nagios?
2. It's possible to set up cacti NPC to work with a different prefix? I still log on a different host, having diffferent database and different prefix.
3. It's possible do set up cactiNPC to have external command enabled for a remote host? As allready written, the nagios server is not the same server as cacti.
Thank's a lot!
Simon
I've installed this plugin, but have some quesitons:
I've 3 servers, every server has it own service running:
1.st server for cacti
2.nd server for nagios
3.th server with database and NDO2DB
I've a Nagios server with ND02DB in production that log all the content to an esternal server on MySQL.
1. It's possible to set up cacti NPC to work with an external nagios?
2. It's possible to set up cacti NPC to work with a different prefix? I still log on a different host, having diffferent database and different prefix.
3. It's possible do set up cactiNPC to have external command enabled for a remote host? As allready written, the nagios server is not the same server as cacti.
Thank's a lot!
Simon
Hi,
Check the rrd file ds name. Must be the same as the output ds name.
rrdtool info choosethis_644.rrd | grep ds
output should report something like
ds[designGallery(secs)]
I dont know this brackets are allowed or not...
Check the same ds info on a working datasource and its data input method profile.
for example load average output:
load1:0.650 load5:0.180 load15:0.060
and the rra ds names are:
rrdtool info rra/localhost_load15_17.rrd | grep ds
ds[load1].type = "GAUGE"
ds[load1].minimal_heartbeat = 600
ds[load1].min = 0.0000000000e+00
ds[load1].max = 5.0000000000e+02
ds[load1].last_ds = "0.650"
ds[load1].value = 1.9500000000e+00
ds[load1].unknown_sec = 0
ds[load5].type = "GAUGE"
ds[load5].minimal_heartbeat = 600
ds[load5].min = 0.0000000000e+00
ds[load5].max = 5.0000000000e+02
ds[load5].last_ds = "U"
ds[load5].value = NaN
ds[load5].unknown_sec = 3
ds[load15].type = "GAUGE"
ds[load15].minimal_heartbeat = 600
ds[load15].min = 0.0000000000e+00
ds[load15].max = 5.0000000000e+02
ds[load15].last_ds = "U"
ds[load15].value = NaN
ds[load15].unknown_sec = 3
My problem is why does not get the load5, load15 value?? I can only see load1 in rra file and on the graph.
rrdtool fetch rra/localhost_load15_17.rrd AVERAGE -r 900 -s -1H
load1 load5 load15
1259317500: 7.9533333333e-02 nan nan
1259317800: 5.3333333333e-04 nan nan
Check the rrd file ds name. Must be the same as the output ds name.
rrdtool info choosethis_644.rrd | grep ds
output should report something like
ds[designGallery(secs)]
I dont know this brackets are allowed or not...
Check the same ds info on a working datasource and its data input method profile.
for example load average output:
load1:0.650 load5:0.180 load15:0.060
and the rra ds names are:
rrdtool info rra/localhost_load15_17.rrd | grep ds
ds[load1].type = "GAUGE"
ds[load1].minimal_heartbeat = 600
ds[load1].min = 0.0000000000e+00
ds[load1].max = 5.0000000000e+02
ds[load1].last_ds = "0.650"
ds[load1].value = 1.9500000000e+00
ds[load1].unknown_sec = 0
ds[load5].type = "GAUGE"
ds[load5].minimal_heartbeat = 600
ds[load5].min = 0.0000000000e+00
ds[load5].max = 5.0000000000e+02
ds[load5].last_ds = "U"
ds[load5].value = NaN
ds[load5].unknown_sec = 3
ds[load15].type = "GAUGE"
ds[load15].minimal_heartbeat = 600
ds[load15].min = 0.0000000000e+00
ds[load15].max = 5.0000000000e+02
ds[load15].last_ds = "U"
ds[load15].value = NaN
ds[load15].unknown_sec = 3
My problem is why does not get the load5, load15 value?? I can only see load1 in rra file and on the graph.
rrdtool fetch rra/localhost_load15_17.rrd AVERAGE -r 900 -s -1H
load1 load5 load15
1259317500: 7.9533333333e-02 nan nan
1259317800: 5.3333333333e-04 nan nan
trevorj wrote:I am having trouble graphing the information from NPC.
The data input method is working:
From the Cacti log:
11/06/2009 12:30:02 PM - CMDPHP: Poller[0] Host[0] DS[644] CMD: php /var/www/cacti/plugins/npc/perfdata.php --type=service --id=264 2> /dev/null, output: designGallery(secs):1.329221
From the command line:
[root@xxx rra]# php /var/www/cacti/plugins/npc/perfdata.php --type=service --id=264 2> /dev/null
designGallery(secs):2.135832
However if I use rrdtool to fetch the rrd:
[root@xxx rra]# rrdtool fetch choosethis_644.rrd AVERAGE
choosethis
1257454200: nan
1257454500: nan
1257454800: nan
1257455100: nan
1257455400: nan
1257455700: nan
1257456000: nan
1257456300: nan
1257456600: nan
1257456900: nan
1257457200: nan
1257457500: nan
1257457800: nan
1257458100: nan
1257458400: nan
It returns all NaNs.
Debugging the rrd shows it is ok.
I have followed this guide: http://www.cacti.net/downloads/docs/html/how_to.html over and over
I would really appreciate any help with this problem.
Sini
-
- Posts: 1
- Joined: Mon Nov 30, 2009 11:29 am
NPC 2.0.4 on Debian Lenny with Nagio 3.0.6 - no hosts/servic
Hi,
I have installed NPC 2.0.4 on Debian Lenny according to the quick start guide on http://trac2.assembla.com/npc/.
I have everything working so far. The npc_* tables in the database are populated partly (there is the necessary entries in npc_hosts, e.g., but nothing in npc_hoststatus). There is no data sink errors in cacti log.
I do not see any host status or service status in the npc tab, nagios status is everything green.
In Console => devices I only have localhost, but with defined nagios host mapping it should show up in the npc pane, should it not? It does not.
I have carefully screened every post on this problem (and tried every proposed solution), I think, but I do not find what I did wrong.
Any hint or help is appreciated.
I have installed NPC 2.0.4 on Debian Lenny according to the quick start guide on http://trac2.assembla.com/npc/.
I have everything working so far. The npc_* tables in the database are populated partly (there is the necessary entries in npc_hosts, e.g., but nothing in npc_hoststatus). There is no data sink errors in cacti log.
I do not see any host status or service status in the npc tab, nagios status is everything green.
In Console => devices I only have localhost, but with defined nagios host mapping it should show up in the npc pane, should it not? It does not.
I have carefully screened every post on this problem (and tried every proposed solution), I think, but I do not find what I did wrong.
Any hint or help is appreciated.
-
- Posts: 10
- Joined: Mon Jul 16, 2007 10:57 am
Re: NPC 2.0.4 on Debian Lenny with Nagio 3.0.6 - no hosts/se
What version of NDOUtils are you using?dirkhschulz wrote:Hi,
I have installed NPC 2.0.4 on Debian Lenny according to the quick start guide on http://trac2.assembla.com/npc/.
I have everything working so far. The npc_* tables in the database are populated partly (there is the necessary entries in npc_hosts, e.g., but nothing in npc_hoststatus). There is no data sink errors in cacti log.
I do not see any host status or service status in the npc tab, nagios status is everything green.
In Console => devices I only have localhost, but with defined nagios host mapping it should show up in the npc pane, should it not? It does not.
I have carefully screened every post on this problem (and tried every proposed solution), I think, but I do not find what I did wrong.
Any hint or help is appreciated.
Who is online
Users browsing this forum: No registered users and 0 guests