Comments (6)
Can you send in a PR which fixes the issue please? :)
from manubulon-snmp.
My perl knowledge is close to zero, but I think that https://github.com/dnsmichi/manubulon-snmp/blob/master/plugins/check_snmp_int.pl#L718 is the line to modify :/
from manubulon-snmp.
Hm, do you have some sample data then which I could use for further analysis? (plugin output and perfdata on the cli)
from manubulon-snmp.
This is the command line that produces the interface data being shown, as taken from /var/log/icinga2/debug.log
:
'/usr/lib/nagios/plugins/check_snmp_int.pl' '-2' '-B' '-C' 'logisys-monitor' '-H' '172.28.5.3' '-M' '-Y' '-c' '0,600' '-d' '300' '-f' '-k' '-n' '\bpppoe0|\beth1|\btun0' '-t' '5' '-w' '300,400'
And if we enter that as is on the command line the output is:
eth1:UP (0.0Mbps/0.0Mbps), tun0:UP (0.0Mbps/0.0Mbps), pppoe0:UP (0.0Mbps/0.0Mbps):(3 UP): UNKNOWN | 'eth1_in_bps'=1114;300000000;;0;100000000 'eth1_out_bps'=752;400000000;600000000;0;100000000 'tun0_in_bps'=5075;300000000;;0;0 'tun0_out_bps'=3401;400000000;600000000;0;0 'pppoe0_in_bps'=22887;300000000;;0;0 'pppoe0_out_bps'=12744;400000000;600000000;0;0
(The reason for the UNKOWN status is because I removed the parts of the output saying it could not write to the output file in /tmp.)
And the performance data from this output get written to the database as:
perfdata = E'eth1_in_bps=1761;300000000;;0;100000000 eth1_out_bps=969;400000000;600000000;0;100000000 '' ''pppoe0_in_bps''''=23036;300000000;;0;0 pppoe0_out_bps=12687;400000000;600000000;0;0 '' ''tun0_in_bps''''=4569;300000000;;0;0 tun0_out_bps=3055;400000000;600000000;0;0'
There are three things to note:
-
The first is only apparent when looking at a full debug.log. The interfaces are not always returned in the same order. Each in/out pair is listed alternately in first position.
-
In the command line output, the pairs are separated by two spaces, while the in|out counters are separated by a single space.
-
Finally, here is how I unpack the database input line:
- Each pair of counters is between single quotes. So the first pair is: 'eth1_in_bps=1761;300000000;;0;100000000 eth1_out_bps=969;400000000;600000000;0;100000000 '.
- The second pair is: ' ''pppoe0_in_bps''''=23036;300000000;;0;0 pppoe0_out_bps=12687;400000000;600000000;0;0 '
- And the last: ' ''tun0_in_bps''''=4569;300000000;;0;0 tun0_out_bps=3055;400000000;600000000;0;0'
The above is part of my internal bug report. The command line above will produce counters:
- eth1_in_bps
- _'pppoe0_in_bps'
- _'tun0_in_bps'
Hope that helps.
from manubulon-snmp.
Hi,
i think, i have the same issue, i use the actually version from this page and use the following command
'/usr/lib64/nagios/plugins/check_snmp_int.pl' '-H' '172xx.xx.xx' '-L' 'sha,des' '-l' 'icinga2' '-X' 'XXX' '-x' 'XXX' '-Y' '-d' '60' '-e' '-f' '-kM' '-n' '48' '-w' '80,80' '-c' '90,90' '-B' '--64bits'
Perfdate Output looks very strange:
'D-Link Corporation DGS-1250-52XMP HW A1 firmware 2_01.006 Port 48_in_error'=0c
In this form i didn't get the grafana graph.
from manubulon-snmp.
Hi,
The problem with the spaces in the interface name - not to mention the length. I don't have a D-Link here: Are ifName or ifAlias better? Have you already tried that?
Otherwise you could think about a PR which converts the names. Convert spaces to _ and shorten the name using a regexp filter. The firmware version actually has no place in a switch port name. I thik "Port_48_in_error" would be enough. It's strange what D-Link is doing here.
from manubulon-snmp.
Related Issues (20)
- check_snmp_int.pl - Quantifier follows nothing in regex HOT 1
- Issues with 2012R2 and check_snmp_mem.pl HOT 1
- Use of uninitialized value $speed_real in concatenation (.) or string at check_snmp_int.pl line 976. HOT 3
- Consider Changing check_snmp_load -T netsl value names HOT 2
- check_snmp_int.pl treats device reboot as octet counters overflow
- SNMP interface check doesn't work with Perl < 5.13.2 HOT 1
- Installation requires perl-bignum on Fedora (likely CentOS/Redhat) for bigint package HOT 3
- check_snmp_mem.pl plugin giving wrong results HOT 5
- check_snmp_load.pl with -T netsl uses wrong oid HOT 4
- check_snmp_int with subinterface return cannot get interface speed using highperf mib : UNKNOWN HOT 3
- Fallback SNMP versions and counter sizes HOT 3
- Maintainer wanted HOT 1
- Error with check_snmp_process.pl with snmpv3 but not check_snmp_storage.pl HOT 3
- SNMP retries not respected due to global timeout HOT 3
- Questen Parameter usage for icinga2 HOT 7
- check_snmp_mem.pl fails with a specific device HOT 4
- check_snmp_storage - multiple warning args HOT 1
- check_snmp_int filling 0 valued rows PALO-ALTO 3220 HOT 1
- check_snmp_process - Slightly confusing error message due to rounding HOT 2
- Add support for SHA-256 auth and AES128 priv
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from manubulon-snmp.