Lee (+ any one else),
Yes, that was the problem that I found. I tried puting 'no such var' but
this stops the snmpwalk prematurly ie. when it tries to read the variable.
I also tried 'no Access' but this as a similar effect.
I have tried to keep the MIB in line with the standards; so I resorted
to making the variables read-write. Now the snmpwalk can be done but the
results it gives for these variables sometimes have little meaning.
I am using the ucd-snmp-220.127.116.11 version which I have stripped and added
to. I noticed that when you set a MIB variable, the response to the set
should include the newly set variable: Book(1).
This does not happen. If the agent sees that the 'set' worked
successfully it just clones the incoming request and packages it up as
Which is where my orginal problem came from. I using at set request, as
a MIB query, ie set a field with a printer name and in the get-response
reply comes the printer status as set by the agent. This is why I wanted
to make the variable write-only, because to read it straight has a value
but no meaning. It would be better if the walk just displayed the write-
only variables as WO and continued on the walk.
I was wandering what the offical thing to do in this situtation is....?
> I suppose you've long since solved this, but we return a
> zero for write-only vars just to avoid this. My understanding
> is that 'no such var' is also a legitimate response, but
> it does break an snmpwalk, which is why we do the former.
> > Hello all,
> > I am writing a manager from the UCD snmp manager which I have hacked.
> > Several of my variables are write only and are used to query the snmp
> > database.
> > Which works find. My problem is when an agent does a GETNEXT request
> > in order to walk through the date-base. It comes to the write-only
> > variable and tries to read it. It failed.
> > What error message must be returned, or what must happen, in order
> > for the snmpwalk to continue.
> > The in-src comments, situated in agent/snmp_agent.c:parse_var_op_list(),
> > suggests that acls for individual variables (of a complete packet) are
> > checked in the agent/snmp_vars.c:getStatPtr() src file.
> > I am unsure of where to put the acl check for the variables.
> > Any help would be appreciated,
> > ------------------------------------------------
> > David Newcomb,
> > Macro4 Open Systems Ltd.
> > Fairfield House,
> > Carey Road,
> > Berkshire,
> > RG40 2NP, Tel: +44 (0)118 989 2626
> > United Kingdom. Fax: +44 (0)118 989 0414
> Lee Slaughter, network management development - submarine stuff
> Navy R & D, Point Loma, San Diego, CA 619-553-5486
> "Giving credence to his ramblings indicates a cognitive disorder..."
> - Lee's psychiatrist, circa 1952
Macro4 Open Systems Ltd.
RG40 2NP, Tel: +44 (0)118 989 2626
United Kingdom. Fax: +44 (0)118 989 0414