configuration help

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
matteo1983
Posts: 1
Joined: Wed Jun 27, 2018 4:30 am

configuration help

Post by matteo1983 »

Hello everyone,
I install today Nagio Core 4.3.2 without any problem: all working fine.
Now I have a problem with configuration of monitoring windows host..
I create I file named hosts.cfg under /usr/local/nagios/etc/servers/ like I see into thi guide, I install in my Windows Server NSClient following the instruction into the guide that I fond online but when I launch command /usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg the server return me this error:

Nagios Core 4.3.2
Copyright (c) 2009-present Nagios Core Development Team and Community Contributors
Copyright (c) 1999-2009 Ethan Galstad
Last Modified: 2017-05-09
License: GPL

Website: https://www.nagios.org
Reading configuration data...
Read main config file okay...
Warning: Duplicate definition found for host '' (config file '/usr/local/nagios/etc/servers/hosts.cfg', starting on line 7)
Error: Could not add object property in file '/usr/local/nagios/etc/servers/hosts.cfg' on line 9.
Error: Host name is NULL
Error: Could not register host (config file '/usr/local/nagios/etc/servers/hosts.cfg', starting on line 7)
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 definitions. 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.

:?: :?: :?: :?: :?: :?: :?: :?: :?: :?: :?: :?: :?: :?: :?: :?: :?: :?: :?: :?: :?:

Can anyone please help me to solve the issue?

Many thanks to all
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: configuration help

Post by scottwilkerson »

Can you share /usr/local/nagios/etc/servers/hosts.cfg

Looks like you are missing the host_name field
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
Locked