Download Simple Network Management Protocol (SNMP)
Transcript
1.3: Instrumentation Functions Table Operations The generation of default functions for tables works for tables which use the RowStatus textual convention from SNMPv2, defined in STANDARD-MIB and SNMPv2-TC. Note: We strongly encourage the use of the RowStatus convention for every table that can be modified from the manager, even for newly designed SNMPv1 MIBs. In SNMPv1, everybody has invented their own scheme for emulating table operations, which has led to numerous inconsistencies. The convention in SNMPv2 is flexible and powerful and has been tested successfully. If the table is read only, no RowStatus column should be used. 1.3.4 Atomic Set In SNMP, the set operation is atomic. Either all variables which are specified in a set operation are changed, or none are changed. Therefore, the set operation is divided into two phases. In the first phase, the new value of each variable is checked against the definition of the variable in the MIB. The following definitions are checked: the type the length the range the variable is writable and within the MIB view. At the end of phase one, the user defined is set ok functions are called for each scalar variable, and for each group of table operations. If no error occurs, the second phase is performed. This phase calls the user defined set function for all variables. If an error occurs, either in the is set ok phase, or in the set phase, all functions which were called with is set ok but not set, are called with undo. There are limitations with this transaction mechanism. If complex dependencies exist between variables, for example between month and day, another mechanism is needed. Setting the date to 'Feb 31' can be avoided by a somewhat more generic transaction mechanism. You can continue and find more and more complex situations and construct an N-phase set-mechanism. This toolkit only contains a trivial mechanism. The most common application of transaction mechanisms is to keep row operations together. Since our agent sorts row operations, the mechanism implemented in combination with the RowStatus (particularly 'createAndWait' value) solve most problems elegantly. Simple Network Management Protocol (SNMP) 23