help configuring nagios-mysql with nagiosgraph

John Stile john at stilen.com
Thu Oct 6 01:07:11 CEST 2005


On Tue, 2005-10-04 at 10:45 +1000, John Stevens wrote:
> perfdata not recognised, usually means that the performance data
> passed to nagiosgraph did not match any of the map file's definitions.
> Read up on perl regexps and look at the map file.  It is pretty well
> documented.  Then look at your output
> 
> On 10/4/05, John Stile <john at stilen.com> wrote:
>         The rrd directory is world writable, but no databases are
>         created.
>         
>         The nagiosgraph log shows 'perfdata not recognized'
>                 Fri Sep 30 18:06:21 2005 INSERT info: Input lastcheck:
>                 Fri Sep 30 18:06:21 2005 INSERT info: Input hostname: 
>                 Fri Sep 30 18:06:21 2005 INSERT info: Input perfdata:
>                 Fri Sep 30 18:06:21 2005 INSERT info: Input
>         servicedescr:
>                 Fri Sep 30 18:06:21 2005 INSERT info: Input output:
>                 Fri Sep 30 18:06:21 2005 INSERT warn: perfdata not
>         recognized  
> This shows me that nagiosgraph is not receiving any information.
> There is no data for lastcheck, hostname, perfdata, servicedescr, or
> output.  In otherwords, at best, an empty line.  What is your
> nagios.cfg file like?
> You should have lines like this:
> host_perfdata_command=process-host-perfdata
> service_perfdata_command=process-service-perfdata
> process_performance_data=1
> in nagios.cfg, and
> # 'process-service-perfdata' command definition
> define command{
>         command_name    process-service-perfdata
>         command_line    /usr/local/bin/exec_perf "$HOSTNAME$"
> "$SERVICEDESC$" "$SERVICESTATE$" "$OUTPUT$" "$PERFDATA$" "$LASTCHECK$"
> }
> in misccommands.cfg.  Sorry, I am not familiar with MySQL nagios
> backend, but unless you have these set up, and you know what kind of
> data is being passed to your process-service-data command, and the map
> file recognises your performance data and how to handle it,
> nagiosgraph will not produce rrds.  It is the process-service-perfdata
> command that creates the rrds and updates them with new data.
> 
> Regards
> Watching the logs, I never see an INSERT statement.  The logged INSERT
> statement in my original email was because I ran insert.pl from the
> console with no options, so that is why all the data is missing.

I'm stick stuck.  What seems insane usually is due to a type-o, but I really need some
help on where to look next.

>From the ground up: 
1. Compile flags for the Debian-3.1 package nagios-common (nagios v1.3):
./configure --prefix=/usr \
        --mandir=/usr/share/man \
        --bindir=/usr/sbin \
        --sbindir=/usr/lib/cgi-bin/nagios \
        --datadir=/usr/share/nagios/htdocs \
        --sysconfdir=/etc/nagios \
        --infodir=/usr/share/info \
        --libexecdir=/usr/lib/nagios/plugins \
        --localstatedir=/var/log/nagios \
        --with-ping-command="/bin/ping -n %s -c %d" \
        --with-mail=/usr/bin/mail --with-perlcache \
        --with-nagios-user=nagios \
        --with-nagios-grp=nagios \
        --with-template-objects \
        --build=$(DEB_BUILD_GNU_TYPE) \
        --host=$(DEB_HOST_GNU_TYPE) \
        --with-pgsql-xdata \
        --with-mysql-xdata \
        --with-template-extinfo

2. In /etc/nagios/nagios.conf: 
  process_performance_data=1
  service_perfdata_command=process-service-perfdata

3. In /etc/nagios/misccommands.cfg 
define command {
  command_name  process-service-perfdata
  command_line  /usr/share/nagios/nagiosgraph/insert.pl  "$HOSTNAME$" "$LASTCHECK$||$HOSTNAME$||$SERVICEDESC$||$OUTPUT$||$PERFDATA$"  >> /var/log/nagios/host-perfdata.out
}

4. Permissions on log files and rrd directory are 777, owned by nagios
daemon user and apache daemon group.

5. Nothing goes into /var/log/nagios/host-perfdata.out, no rrd databases
are created.

So what does that tell me?  It appears to mean that perfdata is never
sent to  process-service-perfdata command?

So do I load a bullet in the gun at this point?
Is the problem that --with-template-extinfo was used and it must be
--with-default-extinfo?  Are they are mutually exclusive?




-------------------------------------------------------
This SF.Net email is sponsored by:
Power Architecture Resource Center: Free content, downloads, discussions,
and more. http://solutions.newsforge.com/ibmarch.tmpl
_______________________________________________
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