How to support GetNextRequest in scotty agent where rows come and go?

Peder Chr. Norgaard (pcn@tbit.dk)
Tue, 25 Jul 1995 11:43:57 +0200 (CDT)

Hello everybody

I need to implement, for testing a MIB under development, an
SNMP agent that works as a proxy, translating the SNMP requests to a
private management protocol.

The scotty tools looks like a godsend for my purpose, as I
already have a Tcl extension that supports the private management
protocol.

I have succeded in combining the two (scotty 1.99.6, tcl7.4
and the private manegement implementation) and have now a very simple
proxy agent running. It really runs, responding correctly to
GetRequests and GetNextRequests, but it needs to know too much about
the target to be useful.

Thus my question No 1, cooked down to a general question:
there are lists of objects in the target that come and go without
telling the proxy agent. In the MIB these lists are represented with
conceptual tables. But the agent cannot maintain up-to-date knowledge
about which rows are present in a table at any given time; it needs to
ask the target via the private management protocol whenever a
GetRequest with explict index, or a GetNextRequest that would move
into a new row is to be answered.

The private management operations for moving from row to row
are simple; what I cannot figure out from the documentation and the
examples is where to hook the calls of these operations into the
scotty agent instance tree, creating rows as needed.

Also the proxy agent need to be able to react to certain kind
of exceptions from the private management protocol requests by
removing rows from the scotty agent instance tree, mapping the fact
that an object has disappeared. Again, I cannot figure out how to
hook these operations in the tree so that (for example) a GetRequest
to such a "dead object" results in a proper SNMP error message,
whereas a GetNextRequest to same object would result in the agent
moving to the next instance in the tree.

Thank you very much in advance for any information on this subject.

best regards

Peder Chr. Norgaard
Telebit Communication A/S,
Denmark.