I am new to Nagios. I recently installed it. I currently have the nagios host running. It is monitoring one client server using the Nagios Remote Plugin Executor (nrpe).
I hope that someone can help me, as assistance would be greatly appreciated.
I am trying to define a new service to monitor the root hard disk.
I currently have the following.
Code: Select all
define service {
use generic-service
host_name nagc1
service_description disk
command_name check_disk
command_line /usr/lib64/nagios/plugins/check_disk -v / -c 5 -w 7
}
when I try and restart the nagios service I get the following error:
Code: Select all
[root@nagios1 servers]# service nagios start
Starting nagios:CONFIG ERROR! Start aborted. Check your Nagios configuration.
Code: Select all
[root@nagios1 servers]# nagios -v clientone.cfg
Nagios Core 3.5.1
Copyright (c) 2009-2011 Nagios Core Development Team and Community Contributors
Copyright (c) 1999-2009 Ethan Galstad
Last Modified: 08-30-2013
License: GPL
Website: http://www.nagios.org
Reading configuration data...
Error in configuration file '/etc/nagios/servers/clientone.cfg' - Line 1 (NULL value)
Error processing main config file!
***> The name of the main configuration file looks suspicious...
Make sure you are specifying the name of the MAIN configuration file on
the command line and not the name of another configuration file. The
main configuration file is typically '/usr/local/nagios/etc/nagios.cfg'
***> 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.