Keith,
Glad to see that you are playing with the NSA!
The snmp.walk is operating in chunks of 300 oids per run. The next version of the NSA (1.04) will allow you to add a fourth parameter to snmp.walk stating the maximum number oids returned per request. This will give you a large single table to work with.
The solution is to repetitively call the snmp.walk until the walk is completed. The returned table contains 3 elements that are critical to succeeding in this task. They are also exposed in the example_snmp script, but should also be addressed in the documentation (I'll fix that in 1.04). Anyway, pay attention to the done, numoids and the lastoid element (as well as the oids table) .
printf ("--------")
h = snmp.create (1,"193.71.55.245","public")
out = snmp.walk (h,"1.3.6.1.2.1","1.3.6.1.2.1")
idx = 0
while out ~= nil do
for i=0,out.numoids-1 do
printf ("%d oid: %s, type: %s", idx, out.oids.oid, out.oids.type)
idx=idx+1
end
if out.done == 1 then break end
out = snmp.walk (h,out.lastoid,"1.3.6.1.2.1")
end
snmp.delete(h)
The lastoid and root oid is too limit the request starting point (starting from the lastoid in the previous walk but within the base of root oid)
Hope this clears things up,
Carstein
PS. NSA v. 1.04 will leave my desk shortly...