Page 1 of 1

Error verify configuration

Posted: Thu Apr 23, 2015 12:26 pm
by paulol
When i click on button Delete All Host / Service -> Write Configs To File - > Verify Configuration i got the following error:

Error: Could not find a service matching host name 'Site LBV' and description 'Status' (config file '/usr/local/nagios/etc/servicegroups.cfg', starting on line 338)
Error: Could not expand members specified in servicegroup 'Sites' (config file '/usr/local/nagios/etc/servicegroups.cfg', starting at line 338)

define servicegroup {
servicegroup_name Sites
alias Sites da IBVs
members Site LBV,Status,Site do Paraguay,Status,Site Uruguay,Status,Site AVA,Status,Site Portugal,Status,Site LGW,Status,Site Paiva Netto,Status,Site TBV,Status,Site Argentina,Status,Site Bolivia,Status,Site Religiao de Deus,Status,Site Boa Vontade,Status

}

define host {
host_name Site LBV
use xiwizard_website_host
alias Site LBV
address http://www.lbv.org
max_check_attempts 5
check_interval 5
retry_interval 1
check_period xi_timeperiod_24x7
flap_detection_enabled 0
contacts nagiosadmin
contact_groups Equipe_DB,Equipe_WEB
notification_interval 60
notification_period xi_timeperiod_24x7
notifications_enabled 0
icon_image www_server.png
statusmap_image www_server.png
_xiwizard website
register 1
}

and when i go to apply configuration button i got this error:

Re: Error verify configuration

Posted: Thu Apr 23, 2015 2:57 pm
by jdalrymple
paulol wrote:Error: Could not find a service matching host name 'Site LBV' and description 'Status'

Sorry, I don't mean to state the obvious, but I can't see anywhere that you've defined that service. Maybe I'm totally missing it though? Wouldn't be the first time.

Re: Error verify configuration

Posted: Fri Apr 24, 2015 12:06 am
by paulol
No, you are right, some services he didnt export to directory nagios files like ROMA.cfg and Site LBV.cfg

After i Apply many times he created the files Site LBV.cfg e ROMA.cfg into services directory.

Do you know why this happen?

Re: Error verify configuration

Posted: Fri Apr 24, 2015 9:54 am
by lmiltchev
Nagios cannot start or restart with a bad configuration. On config errors, Nagios will revert back to the last good known checkpoint.

Re: Error verify configuration

Posted: Fri Apr 24, 2015 12:22 pm
by paulol
Understood...

But what im doing wrong?

For example: let's take the services from ROMA.cfg file.

Code: Select all

Error: Service has no hosts and/or service_description (config file '/usr/local/nagios/etc/services/ROMA.cfg', starting on line 80)

Re: Error verify configuration

Posted: Fri Apr 24, 2015 1:43 pm
by ssax
Your configuration that you posted looks proper, are you receiving that error now?

If you are (or if it happens again), run these commands and post the output:

Code: Select all

cd /usr/local/nagiosxi/scripts
./reconfigure_nagios.sh

Re: Error verify configuration

Posted: Tue May 26, 2015 2:25 pm
by paulol
You can close the threat. Somehow the problem was gone.

Thanks.