On Tue, Aug 20, 2019 at 06:14:34PM +0530, Krishna Chaitanya wrote:
> Hi,
> 
> When using MAC Address as an index ( I am using MacAddress type from
> SNMPv2-TC.) the output is incorrect because the length of the string
> is prefixed as mac address is defined as OCTET STR there is an extra
> byte and the last byte of mac address is interpreted as next OID.
> 
> snmpwalk:
>    HistValue."wlp8s0f0".'....B.'.hist_2.2.19
> snmpwalk -OX
>   HistValue["wlp8s0f0"][STRING: 06:00:90:e6:42:99][hist_2][2].19
> 
> In the above examples last but one OID 2 is hist_2. Is there a way to
> disable prefixing of length?

See RFC 2578, clause 7.7. You define your MAC address as an OCTET STRING
(SIZE(6)), then there is no need to prefix the length.

/Niels

-- 
Niels Baggesen - @home - Ã…rhus - Denmark - n...@users.sourceforge.net
The purpose of computing is insight, not numbers   ---   R W Hamming


_______________________________________________
Net-snmp-coders mailing list
Net-snmp-coders@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders

Reply via email to