Hi Coders,

I have a query regarding the SET phases for table objects.

The phases of SET are as follows:
MODE_SET_RESERVE1    0
MODE_SET_RESERVE2    1
MODE_SET_ACTION        2
MODE_SET_COMMIT      3
MODE_SET_FREE             4
MODE_SET_UNDO           5

SCALAR Objects:
When I do SET with multiple varbinds on scalar objects, say for below command.

snmpset -v2c -c private localhost  var1.0  i  123  var2.0 s "abcde"

the phases of SET are as follows called from handle_set_loop()

               var1                                     var2                    
                 var1                                     var2                  
                   var1                                     var2                
                     var1                                     var2
MODE_SET_RESERVE1  ->  MODE_SET_RESERVE1 -> MODE_SET_RESERVE2 -> 
MODE_SET_RESERVE2 -> MODE_SET_ACTION -> MODE_SET_ACTION -> MODE_SET_COMMIT -> 
MODE_SET_COMMIT.



TABLE Objects:
When I do SET with multiple varbinds on Table objects, say for below command,

Snmpset -v2c -c private localhost  snmpvar1.1.4.5 i 123  snmpvar2.2.4.5 s 
"abcde"

the phases of SET are as follows called from handle_set_loop()

               Var1                                     var1                    
                 var1                                     var1
MODE_SET_RESERVE1 -> MODE_SET_RESERVE2 -> MODE_SET_ACTION -> MODE_SET_COMMIT

               Var2                                     var2                    
                 var2                                     var2
MODE_SET_RESERVE1 -> MODE_SET_RESERVE2 -> MODE_SET_ACTION -> MODE_SET_COMMIT
Here, the SET phases are completed for var1 first and then to var2. If there is 
any failure in setting var2, it won't affect the SET on var1.


The phases of SET are different for scalars and table objects. The phases for 
scalar objects is as per RFC 3416 but not table objects.

I need to understand whether netsnmp itself has a different SET phase for table 
objects and  scalar objects or have I done something wrong in coding ?

Appreciate any response.

Thanks in advance.

Regards,
Madhu

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Net-snmp-coders mailing list
Net-snmp-coders@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders

Reply via email to