Hi Niels,I am using net-snmp versioned 5.4.2.1The output with -Ox is as
below:iso.0.8802.1.1.2.1.4.1.1.11.42980241.587.0 = Hex-STRING 32 30
With regards,Biswajit
> Date: Wed, 27 Jul 2011 09:34:30 +0200
> From: [email protected]
> To: [email protected]
> CC: [email protected]
> Subject: Re: Decoding BITS format in net-snmp
>
> On Wed, Jul 27, 2011 at 12:21:09PM +0530, Biswajit Mandal wrote:
> >
> > Hi net-snmp-coders,
> > This is generic question regarding the SNMP Syntax BITS.
> > We are implementing LLDP MIB. While implementing
> > lldpLocSysCapSupported (Syntax BITS),
> > SYNTAX BITS {
> > other(0),
> > repeater(1),
> > bridge(2),
> > wlanAccessPoint(3),
> > router(4),
> > telephone(5),
> > docsisCableDevice(6),
> > stationOnly(7)
> > }
> > For our case we are getting the value as 20,
> > Now without loading this lldp MIB, we are getting the value
> > iso.0.8802.1.1.2.1.4.1.1.11.42949992.583.0 = STRING: "20"
> > But when we are loading the MIB and trying to do snmpwalk, then
> > net-snmp is decoding this data as
> > LLDP-MIB::lldpRemSysCapEnabled.42949992.583.0 = BITS: 14 10 08 D5
> > wlanAccessPoint(3) telephone(5) 11 20 24 25 27 29 31
> > So want to know how net-snmp decodes this data, basically 20 is
> > valid value as it is a bridge we are implementing.
>
> It seems that you are confusing a binary OCTET STRING, with a DisplayString.
>
> Your BITS value should be an OCTET STRING with a single octet of value
> 0x20.
> Your value seems to be an OCTET STRING with two octets of value 0x32 0x30
> (ASCII characters "2" and "0")
>
> I can't explain what happened to the BITS decoding. What version of
> Net-SNMP is this? What is the output when using -Ox and not loading
> the MIB?
>
> /Niels
>
> --
> Niels Baggesen - @home - Ã…rhus - Denmark - [email protected]
> The purpose of computing is insight, not numbers --- R W Hamming
------------------------------------------------------------------------------
Got Input? Slashdot Needs You.
Take our quick survey online. Come on, we don't ask for help often.
Plus, you'll get a chance to win $100 to spend on ThinkGeek.
http://p.sf.net/sfu/slashdot-survey
_______________________________________________
Net-snmp-coders mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders