Open nook24 opened 5 years ago
well, the reason is that naemon considers warnings as ok for host checks. Consider a Ping which results in a few packets lost so check_ping results in a warning. So Naemon assumes the host is still up, because a host can either be up or down and you either cut the line between ok and warning or warning and critical.
But i agree, instead of letting people read the source, we could simply write into the docs, that warnings are considered UP
for hosts unless you use this option.
From the docs:
Plugin Return Code | Service State | Host State |
---|---|---|
0 | OK | UP |
1 | WARNING | UP or DOWN/UNREACHABLE* |
2 | CRITICAL | DOWN/UNREACHABLE |
3 | UNKNOWN | DOWN/UNREACHABLE |
State 1: UP or DOWN/UNREACHABLE*
This sounds like Schrödinger's host state^^
Until now i thought Host states: 0 = Up 1 = Down 2 = Unreachable
Service states: 0 = Ok 1 = Warning 2 = Critical 3 = Unknown
May be a better name would be use_service_exit_codes_for_host_states
instead of use_aggressive_host_checking
?
Maybe I'm just missing something but is there a documentation available of what
use_aggressive_host_checking
is doing?naemon.cfg
suggests tocheck out the source code
which is not helpful at all.The reason i ask is. I created a check plugin like this for my host check:
My Host was always current_state=0 Up. It took me two hours to find out that
use_aggressive_host_checking=0
was the reason for this, so what the heck is this option about? Tested with Naemon 1.0.7 and 1.0.8.From the docs:
Naemon tries to be smart
. Is always Up really that smart? :)