Question

Assume a MIB contains a table indexed by MAC address. What's the correct behavior by the agent when a manager requests myTable.0.1? This is an incomplete index.

Some possibilities that I see:

  1. Return the first row in the table -- treat this partial index as coming before the first row.
  2. Treat this as a subtree -- return rows in the table that match this MAC prefix.
  3. Return no rows -- treat this as coming after the last row in the table.
  4. Return some kind of error?
Was it helpful?

Solution

Depends on the operation.

A GET on an incomplete OID will return noSuchName.

A GETNEXT on an incomplete OID will return the next complete OID.

Note that many manufacturers fail to implement SNMP agents correctly. You can't always count on them to return the next OID as expected.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top