Page 1 of 1

BUG check_users v2.1.4 (nagios-plugins 2.1.4)

Posted: Mon Feb 27, 2017 6:24 am
by simvirus
Dear Team,
yesterday yum updated my nagios/plugin to 2.1.4-3.el6.x86_64

Now this definition about check_users is not working:

Code: Select all

# /usr/lib/nagios/plugins/check_users -w0 -c1

check_users: Warning threshold must be a positive integer
Usage:
check_users -w <users> -c <users>
but in all other version this was correctly with:

0 user = OK
1 user = WARNING
2 users = CRITICAL

How to fix it?

Best regards
Sim

Re: BUG check_users v2.1.4 (nagios-plugins 2.1.4)

Posted: Mon Feb 27, 2017 2:21 pm
by mcapra
Here's the diff on that plugin VS the 2.1.3 version:
https://github.com/nagios-plugins/nagio ... ae65fb29e5

It doesn't look like much has changed aside from altering how the thresholds are detected. Rather than altering anything, you could probably just use the 2.1.3 version of the plugin.

I can definitely see where this would be an issue though since it creates a situation where you can't execute a check for 0 users. I would suggest raising an issue on the github:
https://github.com/nagios-plugins/nagios-plugins/

Re: BUG check_users v2.1.4 (nagios-plugins 2.1.4)

Posted: Mon Feb 27, 2017 2:40 pm
by lmiltchev
I was able to recreate the issue. I see that you already reported it on GitHub: https://github.com/nagios-plugins/nagio ... issues/228

Our developers will be looking into this. Thanks for reporting the bug!