issues with nagiosgraph

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Locked
thejrose1984
Posts: 2
Joined: Sun Jan 29, 2017 1:28 pm

issues with nagiosgraph

Post by thejrose1984 »

Hi,

I'm having issues installing nagiosgraph. I am using ansible to deploy a series of configuration changes and, with the exception of the nagiosgraph, everything else works OK. If I remove/disable to nagiosgraph configuration file, nagios works without issues.

Here is the configuration file:

Code: Select all

# process nagios performance data using nagiosgraph
process_performance_data=1
service_perfdata_file=/opt/ng_perfdata
service_perfdata_file_template=$LASTSERVICECHECK$||$HOSTNAME$||$SERVICEDESC$||$SERVICEOUTPUT$||$SERVICEPERFDATA$
service_perfdata_file_mode=a
service_perfdata_file_processing_interval=30
service_perfdata_file_processing_command=process-service-perfdata-for-nagiosgraph

define command {
        command_name            process-service-perfdata-for-nagiosgraph
        command_line            /usr/local/nagiosgraph/bin/insert.pl
}

define service {
        name                    nagiosgraph
        action_url              /nagiosgraph/cgi-bin/show.cgi?host=$HOSTNAME$&service=$SERVICEDESC$
        register                0
}
Here is the output:

Code: Select all

[root@ops-yum-mon01 etc]# /usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg

Nagios Core 4.2.4
Copyright (c) 2009-present Nagios Core Development Team and Community Contributors
Copyright (c) 1999-2009 Ethan Galstad
Last Modified: 12-07-2016
License: GPL

Website: https://www.nagios.org
Reading configuration data...
   Read main config file okay...
Error: Unexpected token or statement in file '/usr/local/nagios/etc/conf.d/perfdata.cfg' on line 2.
Error: Invalid max_check_attempts value for host 'localhost'
Error: Could not register host (config file '/usr/local/nagios/etc/objects/localhost.cfg', starting on line 24)
   Error processing object config files!


***> One or more problems was encountered while processing the config files...

     Check your configuration file(s) to ensure that they contain valid
     directives and data defintions.  If you are upgrading from a previous
     version of Nagios, you should be aware that some variables/definitions
     may have been removed or modified in this version.  Make sure to read
     the HTML documentation regarding the config files, as well as the
     'Whats New' section to find out what has changed.
Troubleshooting done thus far:
- Confirmed and, when necessary, remove duplicate variable declarations
- Restarted nagios with and without the perfdata.cfg file (restarting without it works)

OS = CentOS Linux release 7.3.1611 (Core)
Nagios Version = 4.2.4
NagiosGraph Version = 1.5.2
dwhitfield
Former Nagios Staff
Posts: 4583
Joined: Wed Sep 21, 2016 10:29 am
Location: NoLo, Minneapolis, MN
Contact:

Re: issues with nagiosgraph

Post by dwhitfield »

nagiosgraph is not our product, so it may take some time to troubleshoot this. There are definitely a few posts here on the topic, so some of the community members are definitely using it.

That said, do you have a host_perfdata_file setting in your nagios.cfg? It's probably worth going ahead and posting your nagios.cfg if looking for host_perfdata_file doesn't make things click for you.

Also, nagiosgraph has their own forums, which may be of use: https://sourceforge.net/p/nagiosgraph/d ... on/394748/
Locked