Backport fix from Daniel Jakots
Original commit:
The code was taken from check_http_many which apparently deals only with return
codes 0, 1 and 2. Here, we uses check_nrpe which iff it can't connect, it
returns 255
(40717e320c
).
So I decided that if the return code is greater or equal to 2, then we consider
it's critical. I can't see any return code greater than 2 which may not be
critical.
This commit is contained in:
parent
55d05cd4f0
commit
961d9da5e5
|
@ -16,7 +16,7 @@ check_state() {
|
|||
cat $result >> ${result}.err
|
||||
:> $result
|
||||
fi
|
||||
if [[ $1 -eq 2 ]]; then
|
||||
if [[ $1 -ge 2 ]]; then
|
||||
critical=true
|
||||
cat $result >> ${result}.err
|
||||
:> $result
|
||||
|
|
Loading…
Reference in New Issue