Re: API function to extract integer from netsnmp_request_info ?

2011-01-12 Thread Dave Shield
On 12 January 2011 06:07, Abraham Varricatt abraham.varricatt+s...@googlemail.com wrote: what are varbind structures? varbinds are the fundamental mechanism for passing management information between client apps and an SNMP manager. See any SNMP book or primer for more information. The

Re: API function to extract integer from netsnmp_request_info ?

2011-01-12 Thread Abraham Varricatt
varbinds are the fundamental mechanism for passing management information between client apps and an SNMP manager. See any SNMP book or primer for more information. I've got William Stallings SNMP, SNMPv2, SNMPv3 and RMON 1 and 2 with me. From the index, the closest thing I can find is

API function to extract integer from netsnmp_request_info ?

2011-01-11 Thread Abraham Varricatt
I'm playing around with mib2c and am a bit confused with SET commands. I've run this (part of net-snmp examples MIB), mib2c -c mib2c.scalar.conf netSnmpExampleInteger And in the generated code there is a function called snmp_set_var_typed_value(). From experimentation (and code study), I've

Re: API function to extract integer from netsnmp_request_info ?

2011-01-11 Thread Dave Shield
On 11 January 2011 15:52, Abraham Varricatt abraham.varricatt+s...@googlemail.com wrote: there is a function called snmp_set_var_typed_value().. I've figured out that we essentially pass the result of a GET operation into this function, so the snmpd agent will report it back. Correct.

Re: API function to extract integer from netsnmp_request_info ?

2011-01-11 Thread Abraham Varricatt
Is there any function in net-snmp that will let me extract the integer data value that comes with a SET operation out of this structure? requests-requestvb is the varbind structure (of type netsnmp_variable_list) so the value is held in the (union) structure requests-requestvb-val So