Master/Agent Why aren't the checks being configured?

So entering icinga2, I started configuring things the way I used to know (with NRPE) only to realize that NRPE is deprecated and we have to use agents on the API. No problem, so I get the master setup and I have all of the systems I want to monitor setup as agents. However, when I check icingaweb, all of my hosts and services are gone which makes sense in that the conf.d is no longer being recursed as per the wizard and the handbook. What I didn’t see in the handbook however, is how the checks are going to be triggered.

I don’t have any hosts or services with icingaweb right now.

Give as much information as you can, e.g.

  • Version used: r2.13.2-1 on icinga master FreeBSD, r2.11.2-1 on linux agents
  • Enabled features on master:
    Disabled features: command compatlog debuglog elasticsearch gelf graphite icingadb ido-pgsql influxdb influxdb2 livestatus opentsdb perfdata statusdata syslog
    Enabled features: api checker ido-mysql mainlog notification

*Enabled features on agents:
Disabled features: command compatlog debuglog elasticsearch gelf graphite influxdb livestatus notification opentsdb perfdata statusdata syslog
Enabled features: api checker mainlog

  • Config validation (icinga2 daemon -C) on master
    [2022-02-19 16:09:07 -0500] information/cli: Icinga application loader (version: r2.13.2-1)
    [2022-02-19 16:09:07 -0500] information/cli: Loading configuration file(s).
    [2022-02-19 16:09:07 -0500] information/ConfigItem: Committing config item(s).
    [2022-02-19 16:09:07 -0500] information/ApiListener: My API identity: icinga.acmecardano.ca
    [2022-02-19 16:09:08 -0500] information/ConfigItem: Instantiated 1 ApiListener.
    [2022-02-19 16:09:08 -0500] information/ConfigItem: Instantiated 244 CheckCommands.
    [2022-02-19 16:09:08 -0500] information/ConfigItem: Instantiated 1 FileLogger.
    [2022-02-19 16:09:08 -0500] information/ConfigItem: Instantiated 1 ApiUser.
    [2022-02-19 16:09:08 -0500] information/ConfigItem: Instantiated 1 Endpoint.
    [2022-02-19 16:09:08 -0500] information/ConfigItem: Instantiated 1 CheckerComponent.
    [2022-02-19 16:09:08 -0500] information/ConfigItem: Instantiated 1 IcingaApplication.
    [2022-02-19 16:09:08 -0500] information/ConfigItem: Instantiated 3 Zones.
    [2022-02-19 16:09:08 -0500] information/ConfigItem: Instantiated 1 IdoMysqlConnection.
    [2022-02-19 16:09:08 -0500] information/ConfigItem: Instantiated 1 NotificationComponent.
    [2022-02-19 16:09:08 -0500] information/ScriptGlobal: Dumping variables to file ‘/var/cache/icinga2/icinga2.vars’
    [2022-02-19 16:09:08 -0500] information/cli: Finished validating the configuration file(s).

on agent:
root@acmecore:/etc/icinga2# icinga2 daemon -C
[2022-02-19 21:09:50 +0000] information/cli: Icinga application loader (version: r2.11.2-1)
[2022-02-19 21:09:50 +0000] information/cli: Loading configuration file(s).
[2022-02-19 21:09:50 +0000] information/ConfigItem: Committing config item(s).
[2022-02-19 21:09:50 +0000] information/ApiListener: My API identity: core.acmecardano.ca
[2022-02-19 21:09:50 +0000] information/ConfigItem: Instantiated 1 CheckerComponent.
[2022-02-19 21:09:50 +0000] information/ConfigItem: Instantiated 4 Zones.
[2022-02-19 21:09:50 +0000] information/ConfigItem: Instantiated 1 IcingaApplication.
[2022-02-19 21:09:50 +0000] information/ConfigItem: Instantiated 2 Endpoints.
[2022-02-19 21:09:50 +0000] information/ConfigItem: Instantiated 235 CheckCommands.
[2022-02-19 21:09:50 +0000] information/ConfigItem: Instantiated 1 FileLogger.
[2022-02-19 21:09:50 +0000] information/ConfigItem: Instantiated 1 ApiListener.
[2022-02-19 21:09:50 +0000] information/ScriptGlobal: Dumping variables to file ‘/var/cache/icinga2/icinga2.vars’
[2022-02-19 21:09:50 +0000] information/cli: Finished validating the configuration file(s).

Thanks in advance!
Brodey

Here is what I get when starting the service on the icinga server.

[2022-02-20 12:48:05 -0500] information/cli: Loading configuration file(s).
[2022-02-20 12:48:05 -0500] information/ConfigItem: Committing config item(s).
[2022-02-20 12:48:05 -0500] information/ApiListener: My API identity: icinga.acmecardano.ca
[2022-02-20 12:48:05 -0500] warning/Zone: The Zone object 'relays' has more than two endpoints. Due to a known issue this type of configuration is strongly discouraged and may cause Icinga to use excessive amounts of CPU time.
[2022-02-20 12:48:05 -0500] warning/ApplyRule: Apply rule 'mail-icingaadmin' (in /usr/local/etc/icinga2/zones.d/global-templates/mini.conf: 105:1-105:45) for type 'Notification' does not match anywhere!
[2022-02-20 12:48:05 -0500] warning/ApplyRule: Apply rule 'mail-icingaadmin' (in /usr/local/etc/icinga2/zones.d/global-templates/mini.conf: 112:1-112:48) for type 'Notification' does not match anywhere!
[2022-02-20 12:48:05 -0500] warning/ApplyRule: Apply rule 'apt' (in /usr/local/etc/icinga2/zones.d/global-templates/mini.conf: 8:1-8:19) for type 'Service' does not match anywhere!
[2022-02-20 12:48:05 -0500] warning/ApplyRule: Apply rule 'ping4' (in /usr/local/etc/icinga2/zones.d/global-templates/mini.conf: 16:1-16:21) for type 'Service' does not match anywhere!
[2022-02-20 12:48:05 -0500] warning/ApplyRule: Apply rule 'ssh' (in /usr/local/etc/icinga2/zones.d/global-templates/mini.conf: 21:1-21:19) for type 'Service' does not match anywhere!
[2022-02-20 12:48:05 -0500] warning/ApplyRule: Apply rule '' (in /usr/local/etc/icinga2/zones.d/global-templates/mini.conf: 26:1-26:65) for type 'Service' does not match anywhere!
[2022-02-20 12:48:05 -0500] warning/ApplyRule: Apply rule 'disk' (in /usr/local/etc/icinga2/zones.d/global-templates/mini.conf: 33:1-33:20) for type 'Service' does not match anywhere!
[2022-02-20 12:48:05 -0500] warning/ApplyRule: Apply rule 'icinga' (in /usr/local/etc/icinga2/zones.d/global-templates/mini.conf: 39:1-39:22) for type 'Service' does not match anywhere!
[2022-02-20 12:48:05 -0500] warning/ApplyRule: Apply rule 'load' (in /usr/local/etc/icinga2/zones.d/global-templates/mini.conf: 45:1-45:20) for type 'Service' does not match anywhere!
[2022-02-20 12:48:05 -0500] warning/ApplyRule: Apply rule '' (in /usr/local/etc/icinga2/zones.d/global-templates/mini.conf: 53:1-53:44) for type 'Service' does not match anywhere!
[2022-02-20 12:48:05 -0500] warning/ApplyRule: Apply rule '' (in /usr/local/etc/icinga2/zones.d/global-templates/mini.conf: 61:1-61:47) for type 'Service' does not match anywhere!
[2022-02-20 12:48:05 -0500] warning/ApplyRule: Apply rule 'procs' (in /usr/local/etc/icinga2/zones.d/global-templates/mini.conf: 70:1-70:21) for type 'Service' does not match anywhere!
[2022-02-20 12:48:05 -0500] warning/ApplyRule: Apply rule 'swap' (in /usr/local/etc/icinga2/zones.d/global-templates/mini.conf: 76:1-76:20) for type 'Service' does not match anywhere!
[2022-02-20 12:48:05 -0500] warning/ApplyRule: Apply rule 'users' (in /usr/local/etc/icinga2/zones.d/global-templates/mini.conf: 82:1-82:21) for type 'Service' does not match anywhere!
[2022-02-20 12:48:05 -0500] information/ConfigItem: Instantiated 1 ApiListener.
[2022-02-20 12:48:05 -0500] information/ConfigItem: Instantiated 244 CheckCommands.
[2022-02-20 12:48:05 -0500] information/ConfigItem: Instantiated 1 FileLogger.
[2022-02-20 12:48:05 -0500] information/ConfigItem: Instantiated 1 ApiUser.
[2022-02-20 12:48:05 -0500] information/ConfigItem: Instantiated 4 Endpoints.
[2022-02-20 12:48:05 -0500] information/ConfigItem: Instantiated 1 CheckerComponent.
[2022-02-20 12:48:05 -0500] information/ConfigItem: Instantiated 1 IcingaApplication.
[2022-02-20 12:48:05 -0500] information/ConfigItem: Instantiated 2 NotificationCommands.
[2022-02-20 12:48:05 -0500] information/ConfigItem: Instantiated 4 Zones.
[2022-02-20 12:48:05 -0500] information/ConfigItem: Instantiated 1 TimePeriod.
[2022-02-20 12:48:05 -0500] information/ConfigItem: Instantiated 1 User.
[2022-02-20 12:48:05 -0500] information/ConfigItem: Instantiated 1 UserGroup.
[2022-02-20 12:48:05 -0500] information/ConfigItem: Instantiated 1 IdoMysqlConnection.
[2022-02-20 12:48:05 -0500] information/ConfigItem: Instantiated 1 NotificationComponent.
[2022-02-20 12:48:05 -0500] information/ScriptGlobal: Dumping variables to file '/var/cache/icinga2/icinga2.vars'
[2022-02-20 12:48:05 -0500] information/cli: Finished validating the configuration file(s).
OK
[2022-02-20 12:48:05 -0500] information/cli: Icinga application loader (version: r2.13.2-1)
[2022-02-20 12:48:05 -0500] information/cli: Closing console log.

I can see everything getting picked up as an endpoint and yet I still don’t see any Hosts and Services.

You’ll need to configure a Host and Service. There are a basically two ways to do that - flat files that are included (similar to conf.d) or by using Director. The Configuration Best Practice should be able to provide more detail for your next steps (in planning and implementation).

1 Like

Hi @leeclemens ,

Thank you for your help. I was able to get the director setup via the web, had to figure out hairpin NAT on my OpenBSD firewall as well…but with all of that sorted out I’m back at wondering how to get some basic checks going.

A number of tutorials seem to imply that the auto configuration should have some checks. This is clearly wrong and I have zero checks. The documentation doesn’t show anything about using director’s web interface so I have to go into the back end and see what checks I can use, what parameters to provide and all that.

I’m clearly missing a key point or the documentation is missing something…or I’m not navigating to the right documentation sites.

I can’t speak to the tutorials you read, but did you have a chance to check out the links I provided previously? Director has a Kickstart that should import many commands to get you started creating service templates from (and then applying them to your hosts). There are two config/design paths and any detailed assistance would depend on which way you choose to go.