Nagios inheritance issue
Posted: Wed Mar 08, 2017 5:18 am
Hi,
After long time of use Nagios core 4.1.1 today I noticed a wired behavior I'd say even a bug in inheritance. My configuration is as follows:
Host definition example (similar for all hosts in the group except host name and IP):
Group definition:
and service checks:
What I expect is that all members of the group will have exactly the same thresholds for the ping service - W:250 c:500 ms but it seems that for some reason the last two hosts in the 'members' line are ignored. Nagios presents the command as if they were configured with thresholds 150 and 500. I have changed the order in the list and again last two hosts have different values than whole group. However nagios correctly presents them as members of one group. I have also tried to break the line or use two 'members' line definitions with the same result.
I'd be grateful for any hints why I observe such strange behavior.
Thanks,
PZ
After long time of use Nagios core 4.1.1 today I noticed a wired behavior I'd say even a bug in inheritance. My configuration is as follows:
Host definition example (similar for all hosts in the group except host name and IP):
Code: Select all
define host{
use linux-server ; Name of host template to use
; This host definition will inherit all variables that are defined
; in (or inherited by) the linux-server host template definition.
host_name krplplb02a.example.com
alias krplplb02a
address 10.20.102.5
parents skraesx06.example.com,skraesx07.example.com,skraesx15.example.com
}
Code: Select all
define hostgroup{
hostgroup_name lvs-servers ; The name of the hostgroup
alias LVS Servers ; Long name of the group
members krplplb02b.example.com,krplplb02a.example.com,jctlb03a.example.com,jctlb03b.example.com,krplplb01a.example.com,krplplb01b.example.com,psplb01a.example.com,psplb01b.example.com ; Comma separated list of hosts that belong to this group
}
Code: Select all
define service{
use prod-service-hosting,nagiosgraph ; Name of service template to use
hostgroup_name lvs-servers
service_description PING
first_notification_delay 5
check_command check_ping!250.0,20%!500.0,60%
}
I'd be grateful for any hints why I observe such strange behavior.
Thanks,
PZ