On 05/09/06, Zhang Chuan wrote:
> I think the row can not be avaliable immediately after
> netsnmp_table_data_add_row(), but can be avaliable immediately after
> netsnmp_insert_table_row(). Am I right?


That's too simplistic a description.
Please see my explanation from yesterday.

> 1.Why I can not get the table_entry just after netsnmp_insert_table_row() in
> MODE_SET_RESERVE2? I can only get NULL.



I've just clicked what the problem is.
You're using the table_iterator helper (and
'netsnmp_extract_iterator_context' gives the row to work with). But
you're not using the matching 'netsnmp_insert_iterator_context' call.

netsnmp_insert_table_row belongs to a completely different helper, so
it's not surprising that the iterator doesn't know about it.

You can't mix different table helpers. If you're using the iterator
helper, then use the API calls that belong to it - don't start
throwing in calls from a different helper.


> 2.Why I can not remove a table row when I send a remove command by AdventNet
> Mib browser?


No idea - what does the AdventNet "remove command" actually send?



> 3.Basicly, when the rowStatus is not createAndGo, eg. active(1), what should
> the code do?


No idea - what does an "active" vs "notInService" row mean in the
context of this table?
I checked the descriptions in the MIB file, and they were even less
helpfuil than normal!

> Actually, I have no idea about the rowStatus concept.


I suggest you get hold a copy of "Understanding SNMP MIBs", and read
the section on row creation in that.

In the meantime, you're probably better off ignoring most of the
RowStatus behaviour, and just work with 'createAndGo(4)' and
'destroy(6)' values. That's sufficient for basic operation, until you
can teach yourself the full details.

Dave

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=...057&dat=121642
_______________________________________________
Net-snmp-coders mailing list
Net-snmp-coders@lists.sourceforge.net
https://lists.sourceforge.net/lists/...et-snmp-coders