Re: [lisp-snmp] Broken snmpwalk termination check
Brought to you by:
binghe
|
From: John F. <jf...@ms...> - 2009-01-21 08:46:47
|
Hi Chun Tian,
"Chun Tian (binghe)" <bin...@gm...> writes:
[...]
>>> Maybe I shouldn't use these confused function names, but that's what
>>> the original Lisp-SNMP project called.
How about renaming the old oid->= oid-< to oid-child-of-p and the new
lexical compare to oid-lexical->=?
>>> I don't think your patch on oid compare would work, because what I
>>> want to do in snmp-walk in definitely NOT to check which oid is
>>> "big".
>>>
>>> [Theorem 1] The OID as a number list which appears in a "GetNext PDU"
>>> chain will ALWAYS get bigger and bigger. That's just what the SNMP
>>> protocol defined on GetNextPDU.
>>
>> Yes this is what is supposed to happen. However in practice it does
>> not happen for the MS Windows 2k boxen. They keep returning the same
>> oid from getnext for SNMPv2-SMI::enterprises.77.1.4.1.0.
>>
>> The snmpwalk checks for this and so should we.
>>
>> && snmp_oid_compare(name, name_length,
>> vars->name,
>> vars->name_length) >=
>> 0) {
>> fprintf(stderr, "Error: OID not
>> increasing: ");
>>
>
> What's the correspond VALUE (beside the "same" OID) here? I think SNMP
> agent will reply the same OID on GetNextPDU only if this OID doesn't
> exist in the SNMP agent. I thought I've captured it well (explained in
> your second note)
That is certainly the theory, but in practice there is this check and it
stops us looping forever with a (apparently not too uncommon) broken
agent. . .
> And I'm sorry still don't know the difference between NO-SUCH-INSTANCE
> and NO-SUCH-OBJECT, I cannot find a SNMP agent which reply me NO-SUCH-
> INSTANCE, can you?
No, I've never seen those, I don't understand what the condition is
about.
[...]
|