Page MenuHomeVyOS Platform

SNMP GET broken at least for BGP4-MIB
Closed, WontfixPublicBUG

Description

Hello,

1.2.0-rolling+201901100337 has some issues related to SNMP processing.
Walk and Get requests to exact OID gives "No such instance" result instead of correct value:

Walk returns exact OID:

# snmpwalk -v2c -c public 10.10.10.10 SNMPv2-SMI::mib-2.15.6.1.10.10.3.1.0.24.10.0.1
SNMPv2-SMI::mib-2.15.6.1.10.10.3.1.0.24.10.0.1.2 = INTEGER: 0

Trying to walk exact OID:
# snmpwalk -v2c -c public 10.10.10.10 SNMPv2-SMI::mib-2.15.6.1.10.10.3.1.0.24.10.0.1.2
SNMPv2-SMI::mib-2.15.6.1.10.10.3.1.0.24.10.0.1.2 = No Such Instance currently exists at this OID

Trying to GET exact OID:
# snmpget -v2c -c public 10.10.10.10 SNMPv2-SMI::mib-2.15.6.1.10.10.3.1.0.24.10.0.1.2
SNMPv2-SMI::mib-2.15.6.1.10.10.3.1.0.24.10.0.1.2 = No Such Instance currently exists at this OID

Trying the same host rebooted to VyOS 1.1.8:
# snmpget -v2c -c public 10.10.10.10 SNMPv2-SMI::mib-2.15.6.1.10.10.3.1.0.24.10.0.1.2
SNMPv2-SMI::mib-2.15.6.1.10.10.3.1.0.24.10.0.1.2 = INTEGER: 0

Thanks.

Details

Difficulty level
Normal (likely a few hours)
Version
1.2.0-rolling+201901100337
Why the issue appeared?
Will be filled on close
Is it a breaking change?
Unspecified (possibly destroys the router)
Issue type
Unspecified (please specify)

Event Timeline

Unknown Object (User) updated the task description. (Show Details)Feb 7 2021, 8:52 AM
Unknown Object (User) changed Difficulty level from Unknown (require assessment) to Normal (likely a few hours).
Unknown Object (User) set Is it a breaking change? to Unspecified (possibly destroys the router).
root@r2-lts:/home/vyos# snmpget -v 2c -c public 192.168.122.11 IF-MIB::ifAdminStatus.1
IF-MIB::ifAdminStatus.1 = INTEGER: up(1)

@MaxiM In which exact version was a different behavior?
The same result ever in 1.1.8

root@one-dot8:/home/vyos# snmpwalk -v 2c -c public 192.168.122.15 SNMPv2-SMI::mib-2.15.6.1.1
SNMPv2-SMI::mib-2.15.6.1.1.192.168.122.0.24.192.168.122.11 = IpAddress: 192.168.122.11
root@one-dot8:/home/vyos# 
root@one-dot8:/home/vyos# snmpwalk -v 2c -c public 192.168.122.15 SNMPv2-SMI::mib-2.15.6.1.1.1
SNMPv2-SMI::mib-2.15.6.1.1.1 = No Such Instance currently exists at this OID
root@one-dot8:/home/vyos#

Are you sure, that you use the correct mibs??
Most likely you need this? SNMPv2-SMI::mib-2.15.6.1.1. <<

root@one-dot8:/home/vyos# snmpwalk -v 2c -c public 192.168.122.15 SNMPv2-SMI::mib-2.15.6
SNMPv2-SMI::mib-2.15.6.1.1.192.168.122.0.24.192.168.122.11 = IpAddress: 192.168.122.11
SNMPv2-SMI::mib-2.15.6.1.2.192.168.122.0.24.192.168.122.11 = INTEGER: 24
SNMPv2-SMI::mib-2.15.6.1.3.192.168.122.0.24.192.168.122.11 = IpAddress: 192.168.122.0
SNMPv2-SMI::mib-2.15.6.1.4.192.168.122.0.24.192.168.122.11 = INTEGER: 2
SNMPv2-SMI::mib-2.15.6.1.5.192.168.122.0.24.192.168.122.11 = Hex-STRING: 02 02 FD E9 FD EA
SNMPv2-SMI::mib-2.15.6.1.6.192.168.122.0.24.192.168.122.11 = IpAddress: 192.168.122.12
SNMPv2-SMI::mib-2.15.6.1.7.192.168.122.0.24.192.168.122.11 = INTEGER: 0
SNMPv2-SMI::mib-2.15.6.1.8.192.168.122.0.24.192.168.122.11 = INTEGER: 0
SNMPv2-SMI::mib-2.15.6.1.9.192.168.122.0.24.192.168.122.11 = INTEGER: 1
SNMPv2-SMI::mib-2.15.6.1.10.192.168.122.0.24.192.168.122.11 = INTEGER: 0
SNMPv2-SMI::mib-2.15.6.1.11.192.168.122.0.24.192.168.122.11 = IpAddress: 0.0.0.0
SNMPv2-SMI::mib-2.15.6.1.12.192.168.122.0.24.192.168.122.11 = INTEGER: -1
SNMPv2-SMI::mib-2.15.6.1.13.192.168.122.0.24.192.168.122.11 = INTEGER: 1

c-po changed the task status from Open to Needs testing.May 29 2021, 4:39 PM
c-po added a subscriber: c-po.

We have had a lot of tickets about SNMP MIBS for BGP - most of them beeing for IPv6.

I am not an expert on SNMP MIBS but we can now easily extend out MIBS by simply adding the MIB in question to:
https://github.com/vyos/vyos-1x/tree/current/data/mibs

@MaxiM In which exact version was a different behavior?

Are you sure, that you use the correct mibs??
Most likely you need this? SNMPv2-SMI::mib-2.15.6.1.1. <<

I never got true behaviour in VyOS.
Just comparing it to Cisco/JunOS.

dmbaturin edited projects, added VyOS 1.4 Sagitta; removed VyOS 1.2 Crux (VyOS 1.2.9).
dmbaturin set Issue type to Unspecified (please specify).

Since it didn't function properly in either Quagga or FRR...
I suggest addressing this issue to the upstream codebase, as we currently do not maintain SNMP MIBs. Your attention to this matter would be greatly appreciated.