check_icmp only warning

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Post Reply
occ
Posts: 43
Joined: Fri Jan 11, 2019 5:05 am

check_icmp only warning

Post by occ »

HI
I would need the check_icmp, when it has 100% of RTA lost, to generate an alert warning instead of an alert critical.
I tried running:
check_icmp -H HOSTADDRESS -w 200.25,100% -c 200,25,101% but continues to generate a critical alert
Is there a way to disable critical?
swolf

Re: check_icmp only warning

Post by swolf »

Hi @occ, thanks for reaching out.

Based on what I'm seeing, it looks like you never want a critical outcome - is that accurate?
Based on the performance data numbers from my own testing, it looks like check_icmp itself is clamping the packet loss numbers so that your critical threshold of 101% is interpreted as 100%.

If you never need a critical check result, my suggestion is to use the negate plugin. The text of the check will still say "CRITICAL", but the check can be reinterpreted as a WARNING result.

Here's the check definition to reassign critical output to warning:

Code: Select all

/usr/local/nagios/libexec/negate -c WARNING /usr/local/nagios/libexec/check_icmp -H HOSTADDRESS -w '200.25,100%' -c '200.25,100%'
Hopefully that helps - let me know if you have any further questions or concerns.
occ
Posts: 43
Joined: Fri Jan 11, 2019 5:05 am

Re: check_icmp only warning

Post by occ »

Thanks a lot!!
Post Reply