Identifying an instance of an SNMP variable with .0 - SNMP
This is a discussion on Identifying an instance of an SNMP variable with .0 - SNMP ; Hi again,
The way I read RFC 1157, instances of a MIB object should alway be
identified by appending .0 to the object's OID. (RFC1157 section
3.2.6.3)
I'm having issues interpreting this statement. Does it apply to all
Snmp variable ...
-
Identifying an instance of an SNMP variable with .0
Hi again,
The way I read RFC 1157, instances of a MIB object should alway be
identified by appending .0 to the object's OID. (RFC1157 section
3.2.6.3)
I'm having issues interpreting this statement. Does it apply to all
Snmp variable bindings sent on the wire, in all request types? For
example, when I send a trap with some variable bindings in it, should
the OID of every binding always end with .0?
Does this only apply to Snmp v1 or also to v2c and v3?
The reason I ask is that I've looked at some capture files of SNMP
traffic from commercially available network elements, and they do not
always follow this rule. I've seen, for example, v2c notifications
where the first two bindings are sysUpTime.0 and snmpTrapOID.0, but
the following 8 binds had OIDs of "enterprises.388.2.1.8.1.1" or
similar. Am I interpreting the RFC wrong, or is this a case of a
sloppy SNMP implementation?
--
Joel Hansell
Anyone can do any amount of work provided it isn't the work he is supposed
to be doing at the moment. -Robert Benchley
-
Re: Identifying an instance of an SNMP variable with .0
Hi,
OIDs identifying scalar instances should always have a .0 at the end,
however OIDs identifying columnar instances will have the value of the
index (which identifies the row in the table) appended.
For columnar instances, the value can be a single subidentifier (if
e.g. there is a single index of INTEGER based type) or a sequence
of subidentifiers (if the index is e.g. a variable-length string or
if there are several indexes).
In your case it all depends on what enterprises.388.2.1.8.1.1 actually
is - and you will have to read the MIB to figure this out.
Hope this helps,
-- daniel
http://blogs.sun.com/jmxetc
Joel B Hansell wrote:
> Hi again,
>
> The way I read RFC 1157, instances of a MIB object should alway be
> identified by appending .0 to the object's OID. (RFC1157 section
> 3.2.6.3)
>
> I'm having issues interpreting this statement. Does it apply to all
> Snmp variable bindings sent on the wire, in all request types? For
> example, when I send a trap with some variable bindings in it, should
> the OID of every binding always end with .0?
>
> Does this only apply to Snmp v1 or also to v2c and v3?
>
> The reason I ask is that I've looked at some capture files of SNMP
> traffic from commercially available network elements, and they do not
> always follow this rule. I've seen, for example, v2c notifications
> where the first two bindings are sysUpTime.0 and snmpTrapOID.0, but
> the following 8 binds had OIDs of "enterprises.388.2.1.8.1.1" or
> similar. Am I interpreting the RFC wrong, or is this a case of a
> sloppy SNMP implementation?
>