NAGIOSGRAPH not graphing

Sergio Ariel sergio.ariel at iris.uh.cu
Fri Mar 20 14:39:36 CET 2009


I have some similar problem, I have run insert.pl manually and ir return 
this:

*readline() on closed filehandle PERFLOG at 
/usr/local/nagios/etc/nagiosgraph/ngshared.pm line 797*

I went to /usr/local/nagios/etc/nagiosgraph/ngshared.pm line 797 and it 
says:


788 sub inputdata () {
789         my @inputlines;
790         if ( $ARGV[0] ) {
791                 @inputlines = $ARGV[0];
792         } elsif ( defined $Config{perflog} ) {
793                 if (-s $Config{perflog}) {
794                         my $worklog = $Config{perflog} . ".nagiosgraph";
795                         rename($Config{perflog}, $worklog);
796                         open PERFLOG, $worklog;
797                         while (<PERFLOG>) {
798                                 push @inputlines, $_;
799                         }
800                         close PERFLOG;
801                         unlink($worklog);
802                 }

I'm sure I configure logs for perfdata correctly:
*service_perfdata_file* in nagios.cfg is the same file that
*perflog* in nagiosgraph.conf. And I'm sure I put all path correctly in 
any file. I use nagiosgraph 1.2.1
--
Sergio Ariel de la Campa Saiz
    Administrador Red UH


Eric Chatham wrote:
> Hi Patrick,
> 
> Here are my answers.  I hope they give some insight as to the problem.  Thank you.
> 
>> Have you checked out the logs? Is there anything in them?
> 
> Here is a sample of my /var/log/nagiosgraph.log file.  I had the debugging level at (4).  I don't see any INSERT into information though:
> 
> Thu Mar 19 13:34:42 2009 insert.pl warn - perfdata not recognized:
> date||host||desc||out||data for:
> servicedescr: PING
> output: PING OK - Packet loss = 0%, RTA = 0.35 ms
> perfdata:
> Thu Mar 19 13:34:52 2009 insert.pl warn - perfdata not recognized:
> date||host||desc||out||data for:
> servicedescr: PING
> output: PING OK - Packet loss = 0%, RTA = 99.64 ms
> perfdata:
> 
>> Have you tried running the insert command manually to see what happens?
> 
> When I run the insert.pl command manually I get this.
> 
> [root@ ~ sbin]# /usr/local/lib/nagios/insert.pl
> .
> .
> .
> .
> Unquoted string "procs" may clash with future reserved word at (eval 1) line 139.
> Unquoted string "procs" may clash with future reserved word at (eval 1) line 140.
> Unquoted string "smtp" may clash with future reserved word at (eval 1) line 145.
> Unquoted string "response" may clash with future reserved word at (eval 1) line 146.
> Unquoted string "swap" may clash with future reserved word at (eval 1) line 152.
> Unquoted string "swapfree" may clash with future reserved word at (eval 1) line 153.
> Unquoted string "swapwarn" may clash with future reserved word at (eval 1) line 154.
> Unquoted string "swapcrit" may clash with future reserved word at (eval 1) line 155.
> Unquoted string "swapmax" may clash with future reserved word at (eval 1) line 156.
> Unquoted string "procs" may clash with future reserved word at (eval 1) line 162.
> Unquoted string "users" may clash with future reserved word at (eval 1) line 163.
> Unquoted string "uwarn" may clash with future reserved word at (eval 1) line 164.
> Unquoted string "ucrit" may clash with future reserved word at (eval 1) line 165.
> Unquoted string "zombie" may clash with future reserved word at (eval 1) line 170.
> Unquoted string "zombies" may clash with future reserved word at (eval 1) line 171.
> Unquoted string "bps" may clash with future reserved word at (eval 1) line 177.
> 
>> Is it creating RRD files where it's supposed to? Is there data in them?
> [root@ ~sbin]# ls -l /usr/local/nagios/nagiosgraph/rrd/
> total 80
> drwxrwxrwx 2 nagios nagios 4096 Mar 12 14:30  $
> drwxrwxrwx 2 nagios nagios 4096 Mar 12 14:39 ___
> drwxr-xr-x 2 apache apache 4096 Mar 13 15:48 host1
> drwxr-xr-x 2 apache apache 4096 Mar 13 15:48 host2
> drwxrwxrwx 2 nagios nagios 4096 Mar 12 15:08 localhost
> drwxr-xr-x 2 apache apache 4096 Mar 13 15:48 nagiosserver
> drwxrwxrwx 2 nagios nagios 4096 Mar 12 15:08 ny_sap01
> drwxrwxrwx 2 nagios nagios 4096 Mar 12 15:08 ny_sap02
> drwxrwxrwx 2 nagios nagios 4096 Mar 12 15:08 ny_transactional_DB
> drwxrwxrwx 2 nagios nagios 4096 Mar 12 15:08 reach_media
> 
> 
> [root@ ~ sbin]# ls -l /usr/local/nagios/nagiosgraph/rrd/reach_media/
> total 156
> -rwxrwxrwx 1 nagios nagios 47624 Mar 12 15:08 PING___ping.rrd
> -rwxrwxrwx 1 nagios nagios 47624 Mar 12 15:08 PING___ping.rrd_max
> -rwxrwxrwx 1 nagios nagios 47624 Mar 12 15:08 PING___ping.rrd_min
> 
> The graph "template" displays on the page.  That's it though.  There is no data displaying.  According to the last modified date in "reach_media," the graph was last updated on the 12th, the day I installed the program.  Shouldn't the last modified date be now, since the graph continually is updated by insert.pl?
> 
> 
> Eric Chatham
> 
> -----Original Message-----
> From: Patrick Morris [mailto:patrick.morris at hp.com]
> Sent: Thursday, March 19, 2009 14:42
> To: Eric Chatham
> Cc: Nagios Users Mailinglist
> Subject: Re: [Nagios-users] NAGIOSGRAPH not graphing
> 
> Hi Eric!
> 
> On Thu, 19 Mar 2009, Eric Chatham wrote:
> 
>> Please, can someone help me with this?  I installed Nagios 3.0 and Nagiosgraph on a server with CentOS 5.1 i386 version installed.  I am the point now trying to get the graphs to poll PING data.  There is nothing on the graphs.  What is wrong?  I double checked the installation (which I followed the INSTALL instructions that came with the package).  I still can?t find the problem.  Please, help.
> 
> Have you checked out the logs? Is there anything in them?
> 
> Have you tried running the insert command manually to see what happens?
> 
> Is it creating RRD files where it's supposed to? Is there data in them?
> 
> 
> 
> CONFIDENTIAL.  This e-mail and any attached files are confidential and should be destroyed and/or returned if you are not the intended and proper recipient.
> 
> ------------------------------------------------------------------------------
> Apps built with the Adobe(R) Flex(R) framework and Flex Builder(TM) are
> powering Web 2.0 with engaging, cross-platform capabilities. Quickly and
> easily build your RIAs with Flex Builder, the Eclipse(TM)based development
> software that enables intelligent coding and step-through debugging.
> Download the free 60 day trial. http://p.sf.net/sfu/www-adobe-com
> _______________________________________________
> Nagios-users mailing list
> Nagios-users at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/nagios-users
> ::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
> ::: Messages without supporting info will risk being sent to /dev/null
> 

------------------------------------------------------------------------------
Apps built with the Adobe(R) Flex(R) framework and Flex Builder(TM) are
powering Web 2.0 with engaging, cross-platform capabilities. Quickly and
easily build your RIAs with Flex Builder, the Eclipse(TM)based development
software that enables intelligent coding and step-through debugging.
Download the free 60 day trial. http://p.sf.net/sfu/www-adobe-com
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null





More information about the Users mailing list