Icinga Director Not Passing IP Address to hostalive4 Command for Specific Host

Environment Details:

  • OS: Ubuntu 22.04.4 LTS (GNU/Linux 5.15.0-107-generic x86_64)
  • Icinga2 Version: r2.14.2-1
  • Icinga Web 2 Version: v2.12.1
  • Icinga Director Version: 1.11.1

This is in a two-master setup. All the monitored servers share the same Host Template which includes the hostalive4 check.

Issue Description:
I am encountering an issue with Icinga Director where one host is continuously reported as down. The automated check using the hostalive4 command fails due to an incorrect parameter passage where the IP address is not being passed correctly and ends up being an empty string in the automated checks.

Error Message:

check_ping: Invalid hostname/address - 
Usage: check_ping -H <host_address> -w <wrta>,<wpl>% -c <crta>,<cpl>%

Configuration Insight:
The host is configured in Icinga Director with the correct attributes, and manual verification of the address variable returns the correct IP. However, logging of the executed command shows that the -H parameter is passed as an empty string during automated health checks.

Troubleshooting Steps Taken:

  1. Verified hostalive4 command configuration. Variable vars.ping_address = "$address$" is rightly set.
  2. Successfully executed manual ping and check_ping commands directly from the command line.
  3. Restarted Icinga2 service and redeployed configuration changes several times.
  4. Implemented debugging to capture the command execution, which confirmed that the -H parameter receives an empty string.
  5. Checked the icinga2 console output and identified correct address assignment through API retrieval, yet the address fails to be passed to the command in automated checks.
  6. Created a new check command in Icinga Director itself but the variable is still not passed

Discussion Points:

  • Is there any known issue with variable handling in automated check commands in Icinga2 v2.14.2 that might be causing this?
  • Does anyone have suggestions for further diagnostics or has anyone experienced a similar issue with command parameters getting nullified in automated checks?

The issue still persists despite all configurations appearing correct and successful manual checks, suggesting a potential bug or miscommunication between Icinga Director and Icinga2 in handling command parameters for specific hosts.

Any insights, advice, or shared experiences would be greatly appreciated to help resolve this monitoring anomaly. Thank you in advance for your assistance!

In the host itself, did you set the host address attribute?

Correct, similar to how the others were set up

I believe I figured it out somewhere along the line between clearing out the cache on the secondary master, removing stuff in zones.d in the secondary master, and finding out that for some reason icingadb-redis does not seem to like having requirepass enabled. Thanks!