Our nagios software is reporting Error: Could not expand hostgroups and/or hosts specified in service

The error is the only info we can find. The directives appear to be correct - they are similar to ones that worked earlier in the run. Is there a way we can tell Nagios to give us more details on what issue it is having?

Most web hits for this error are by users who found additional errors during the processing. There are no additional errors in our run. It just says: Processing object config directory ‘/prodc/nagios/etc/vip’… Processing object config file ‘/prodc/nagios/etc/vip/sybsp012.cfg’… Error: Could not expand hostgroups and/or hosts specified in service (config file ‘/prodc/nagios/etc/services/pingprlong.cfg’, starting on line 3) 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.

The file in question says:

Define a service to “ping” a host

define service{ use generic-service ; Name of service template to use hostgroup_name hosts.pingprlong service_description PING servicegroups service.pingprlong max_check_attempts 1 ; Re-check the service up to no times in order to determine its final (hard) state normal_check_interval 1 ; Check the service every 1 minute under normal conditions retry_check_interval 1 ; Re-check the service every minute until a hard state can be determined event_handler ping-status-change check_command check_ping2!1000.0,50%!10000.0,100%!9

check_command check_ping!100.0,20%!500.0,60%


Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer