Listing all Hosts & Services without default contacts or contactgroups defined?
Posted: Thu Apr 03, 2025 1:16 pm
Upon restarting the nagios service, I noticed output warning of Hosts/Services that have no default contacts or contactgroups defined. It would be useful to determine all Host/Services in a similar state, is there a stand-alone script I can run to generate a list?
Code: Select all
Apr 02 18:49:32 nagios nagios[5317]: Warning: Service 'Memory Usage' on host 'hostname1-removed' has no default contacts or contactgroups defined!
Apr 02 18:49:32 nagios nagios[5317]: Warning: Service 'Swap Usage' on host 'hostname1-removed' has no default contacts or contactgroups defined!
Apr 02 18:49:32 nagios nagios[5317]: Warning: Service 'CPU Usage' on host 'hostname2-removed' has no default contacts or contactgroups defined!
Apr 02 18:49:32 nagios nagios[5317]: Warning: Service 'Disk Usage on C:/' on host 'hostname2-removed' has no default contacts or contactgroups defined!
Apr 02 18:49:32 nagios nagios[5317]: Warning: Service 'Memory Usage' on host 'hostname2-removed' has no default contacts or contactgroups defined!
Apr 02 18:49:32 nagios nagios[5317]: Warning: Service 'Swap Usage' on host 'hostname2-removed' has no default contacts or contactgroups defined!
Apr 02 18:49:32 nagios nagios[5317]: Warning: Host 'hostname1-removed' has no default contacts or contactgroups defined!
Apr 02 18:49:32 nagios nagios[5317]: Warning: Host 'hostname2-removed' has no default contacts or contactgroups defined!
Apr 02 18:49:32 nagios nagios[5317]: Warning: Host 'hostname3-removed' has no default contacts or contactgroups defined!