SNMP Check Plugin bug

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
rajasegar
Posts: 1018
Joined: Sun Mar 30, 2014 10:49 pm

SNMP Check Plugin bug

Post by rajasegar »

Nagios xi 2014R1.4

Please fix this problem. Version check in all the check_snmp plugins is broken.
It is comparing integer with string.

Code: Select all

[nagios@nagiosdevxi1 libexec]$  ./check_snmp_storage.pl -V
check_snmp_storage version : 1.3.2


[nagios@nagiosdevxi1 libexec]$ ./check_snmp_storage.pl -H 10.104.28.124  -C xxxxx --v2c -m '^[CDEF]:' -w 80 -c 95 -f
Argument "v6.0.1" isn't numeric in numeric lt (<) at ./check_snmp_storage.pl line 407.
Argument "v6.0.1" isn't numeric in numeric lt (<) at ./check_snmp_storage.pl line 481.
D:\ Label:ZRMSSEL_EN  Serial Number bce4043c: 100%used(411MB/411MB) C:\ Label:  Serial Number dcbc060b: 34%used(2779MB/8182MB) (>95%) : CRITICAL | 'D:\_Label:ZRMSSEL_EN__Serial_Number_bce4043c'=411MB;329;391;0;411 'C:\_Label:__Serial_Number_dcbc060b'=2779MB;6545;7772;0;8182
[nagios@nagiosdevxi1 libexec]$
5 x Nagios 5.6.9 Enterprise Edition
RHEL 6 & 7
rrdcached & ramdisk optimisation
User avatar
Box293
Too Basu
Posts: 5126
Joined: Sun Feb 07, 2010 10:55 pm
Location: Deniliquin, Australia
Contact:

Re: SNMP Check Plugin bug

Post by Box293 »

There is a newer version of the plugin available (1.3.3):

http://nagios.proy.org/snmp_storage.html

Download this and see if it fixes your problem.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
rajasegar
Posts: 1018
Joined: Sun Mar 30, 2014 10:49 pm

Re: SNMP Check Plugin bug

Post by rajasegar »

Box293 wrote:There is a newer version of the plugin available (1.3.3):

http://nagios.proy.org/snmp_storage.html

Download this and see if it fixes your problem.
It is 8 years old. Same problem
This is used by the Nagios Wizard for Windows SNMP and came with XI.
Why is nagios distributing old versions?
5 x Nagios 5.6.9 Enterprise Edition
RHEL 6 & 7
rrdcached & ramdisk optimisation
rajasegar
Posts: 1018
Joined: Sun Mar 30, 2014 10:49 pm

Re: SNMP Check Plugin bug

Post by rajasegar »

I have fixed the bugs and added windows physical memory plugin (fixed for Win2000 based on user feedback in the plugin page, swap remarked)
Names changed to avoid clash with existing plugins

Anybody interested, it is attached below.
SNMP_Fixed.zip
You do not have the required permissions to view the files attached to this post.
5 x Nagios 5.6.9 Enterprise Edition
RHEL 6 & 7
rrdcached & ramdisk optimisation
abrist
Red Shirt
Posts: 8334
Joined: Thu Nov 15, 2012 1:20 pm

Re: SNMP Check Plugin bug

Post by abrist »

Thanks kindly. I have passed the zip on to the devs for review.
rajasegar wrote:Why is nagios distributing old versions?
Mostly because the previous version was stable and the update was incremental. We have also made changes to many of these plugins so the upgrade path to the third party's new versions may have issues.
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
rajasegar
Posts: 1018
Joined: Sun Mar 30, 2014 10:49 pm

Re: SNMP Check Plugin bug

Post by rajasegar »

abrist wrote:Thanks kindly. I have passed the zip on to the devs for review.
rajasegar wrote:Why is nagios distributing old versions?
Mostly because the previous version was stable and the update was incremental. We have also made changes to many of these plugins so the upgrade path to the third party's new versions may have issues.
Ok. Noted.
BTW, I have removed the conditional check for (Net::SNMP->VERSION < 4) in the source_code. This is because I dont use the old version in any of my machines.
However it may not apply to all.

Please close this thread.
5 x Nagios 5.6.9 Enterprise Edition
RHEL 6 & 7
rrdcached & ramdisk optimisation
Locked