📄 rfc2982.txt
字号:
kept and the burden of ongoing processing even when no one is looking at the results. Unfortunately it also makes expressions on counters unusable, as counters have meaning only as deltas. An implementation without deltas might be useful for a severely limited, self-managing system that has no need for expressions or events on counters. Although conceivable, such systems would be rare.2.5. Structure The MIB has the following sections: o Resource -- management of the MIB's use of system resources. o Definition -- definition of expressions. o Value -- values of evaluated expressions.2.5.1. Resource The resource section has objects to manage resource usage by wildcarded delta expressions, a potential major consumer of CPU and memory.2.5.2. Definition The definition section contains the tables that define expressions. The expression table, indexed by expression owner and expression name, contains those parameters that apply to the entire expression, such as the expression itself, the data type of the result, and the sampling interval if it contains delta or change values.Kavasseri & Stewart Standards Track [Page 7]RFC 2982 Distributed Management Expression MIB October 2000 The object table, indexed by expression owner, expression name and object index within each expression, contains the parameters that apply to the individual objects that go into the expression, including the object identifier, sample type, discontinuity indicator, and such.2.5.3. Value The value section contains the values of evaluated expressions. The value table, indexed by expression owner, expression name and instance fragment contains a "discriminated union" of evaluated expression results. For a given expression only one of the columns is instantiated, depending on the result data type for the expression. The instance fragment is a constant or the final section of the object identifier that filled in a wildcard.2.6. Examples The examples refer to tables and objects defined below in the MIB itself. They may well make more sense after reading those definitions.2.6.1. Wildcarding An expression may use wildcarded MIB objects that result in multiple values for the expression. To specify a wildcarded MIB object a management application leaves off part or all of the instance portion of the object identifier, and sets expObjectWildcard to true(1) for that object. For our example we'll use a counter of total blessings from a table of people. Another table, indexed by town and person has blessings just from that town. So the index clauses are: personEntry OBJECT-TYPE ... INDEX { personIndex } And: townPersonEntry OBJECT-TYPE ... INDEX { townIndex, personIndex }Kavasseri & Stewart Standards Track [Page 8]RFC 2982 Distributed Management Expression MIB October 2000 In our friendly application we may have entered our expression as: 100 * townPersonBlessings.976.* / personBlessings.* What goes in expExpression is: 100*$1/$2 For example purposes we'll use some slightly far-fetched OIDs. The People MIB is 1.3.6.1.99.7 and the Town MIB is 1.3.6.1.99.11, so for our two counters the OIDs are: personBlessings 1.3.6.1.99.7.1.3.1.4 townPersonBlessings 1.3.6.1.99.11.1.2.1.9 The rule for wildcards is that all the wildcarded parts have to match exactly. In this case that means we have to hardwire the town and only the personIndex can be wildcarded. So our values for expObjectID are: 1.3.6.1.99.7.1.3.1.4 1.3.6.1.99.11.1.2.1.9.976 We're hardwired to townIndex 976 and personIndex is allowed to vary. The value of expExpressionPrefix can be either of those two counter OIDs (including the instance fragment in the second case), since either of them takes you to a MIB definition where you can look at the INDEX clause and figure out what's been left off. What's been left off doesn't have to work out to be the same object, but it does have to work out to be the same values (semantics) for the result to make sense. Note that the managed system can not typically check such semantics and if given nonsense will return nonsense. If we have people numbered 6, 19, and 42 in town number 976, the successive values of expValueInstance will be: 0.0.6 0.0.19 0.0.42 So there will be three values in expValueTable, with those OIDs as the expValueInstance part of their indexing.Kavasseri & Stewart Standards Track [Page 9]RFC 2982 Distributed Management Expression MIB October 20002.6.2. Calculation and Conditional The following formula for line utilization of a half-duplex link is adapted from [PracPersp]. utilization = (ifInOctets + ifOutOctets) * 800 / seconds / ifSpeed The expression results in the percentage line utilization per second. The total octets are multiplied by 8 to get bits and 100 to scale up the percentage as an integer. The following Expression MIB object values implement this as an expression for all ifIndexes that directly represent actual hardware. Since the octet counters are Counter32 values, they must be delta sampled to be meaningful. The sample period is 6 seconds but for accuracy and independence is calculated as a delta of sysUpTime. The expObjectTable entry for ifInOctets has an expObjectConditional that checks for being a hardware interface. Only one object in the expression needs that check associated, since it applies to the whole expression. Since ifConnectorPresent is a TruthValue with values of 1 or 2 rather than 0 and non-zero, it must also be in an expression rather than used directly for the conditional. The interface-specific discontinuity indicator is supplied only for ifInOctets since invalidating that sample will invalidate an attempt at evaluation, effectively invalidating ifOutOctets as well (correctly, because it has the same indicator). For notational clarity, in the rest of this document, a string in quotes as part of the object instance indicates the value that would actually be one subidentifier per byte. The objects all belong to owner "me". Also for clarity OIDs are expressed as the object descriptor and instance. In fact they must be supplied numerically, with all subidentifiers in place before the part for the particular object and instance. What the user would set in expExpressionTable: expExpression.2."me".4."hard" = "$1==1" expExpressionValueType.2."me".4."hard" = unsigned32 expExpressionRowStatus.2."me"4."hard" = 'active'Kavasseri & Stewart Standards Track [Page 10]RFC 2982 Distributed Management Expression MIB October 2000 expExpression.2."me".4."util" = "($1+$2)*800/$4/$3" expExpressionValueType.2."me".4."util" = integer32 expExpressionDeltaInterval.2."me".4."util" = 6 expExpressionRowStatus.2."me"4."util" = 'active' What the user would set in expObjectTable: expObjectID.2."me".4."hard".1 = ifConnectorPresent expObjectWildcard.2."me".4."hard".1 = 'true' expObjectSampleType.2."me".4."hard".1 = 'absoluteValue' expObjectRowStatus.2."me".4."hard".1 = 'active' expObjectID.2."me".4."util".1 = ifInOctets expObjectWildcard.2."me".4."util".1 = 'true' expObjectSampleType.2."me".4."util".1 = 'deltaValue' expObjectConditional.2."me".4."util".1 = expValueUnsigned32Val.4."hard".0.0 expObjectConditionalWildcard.2."me".4."util".1 = 'true' expObjectDiscontinuityID.2."me".4."util".1 = ifCounterDiscontinuityTime expObjectDiscontinuityIDWildcard.2."me".4."util".1 = 'true' expObjectRowStatus.2."me".4."util".1 = 'active' expObjectID.2."me".4."util".2 = ifOutOctets expObjectWildcard.2."me".4."util".2 = 'true' expObjectSampleType.2."me".4."util".2 = 'deltaValue' expObjectRowStatus.2."me".4."util".2 = 'active' expObjectID.2."me".4."util".3 = ifSpeed expObjectWildcard.2."me".4."util".3 = 'true' expObjectSampleType.2."me".4."util".3 = 'absoluteValue' expObjectRowStatus.2."me".4."util".3 = 'active' expObjectID.2."me".4."util".4 = sysUpTime.0 expObjectWildcard.2."me".4."util".4 = 'false' expObjectSampleType.2."me".4."util".4 = 'deltaValue' expObjectRowStatus.2."me".4."util".4 = 'active' These settings will result in populating one column of expValueTable: expValueInteger32Val.2."me".4."util".0.0.? The subidentifier represented by "?" above represents one subidentifier that takes on a value of ifIndex and identifies a row for each ifIndex value where ifConnectorPresent is 'true' and the interface was present for two samples to provide a delta.Kavasseri & Stewart Standards Track [Page 11]RFC 2982 Distributed Management Expression MIB October 2000 This value could in turn be used as an event threshold [RFC2981] to watch for overutilization of all hardware network connections.3. DefinitionsDISMAN-EXPRESSION-MIB DEFINITIONS ::= BEGINIMPORTS MODULE-IDENTITY, OBJECT-TYPE, Integer32, Gauge32, Unsigned32, Counter32, Counter64, IpAddress, TimeTicks, mib-2, zeroDotZero FROM SNMPv2-SMI RowStatus, TruthValue, TimeStamp FROM SNMPv2-TC sysUpTime FROM SNMPv2-MIB SnmpAdminString FROM SNMP-FRAMEWORK-MIB MODULE-COMPLIANCE, OBJECT-GROUP FROM SNMPv2-CONF;dismanExpressionMIB MODULE-IDENTITY LAST-UPDATED "200010160000Z" -- 16 October 2000 ORGANIZATION "IETF Distributed Management Working Group" CONTACT-INFO "Ramanathan Kavasseri Cisco Systems, Inc. 170 West Tasman Drive, San Jose CA 95134-1706. Phone: +1 408 527 2446 Email: ramk@cisco.com" DESCRIPTION "The MIB module for defining expressions of MIB objects for management purposes."-- Revision History REVISION "200010160000Z" -- 16 October 2000 DESCRIPTION "This is the initial version of this MIB. Published as RFC 2982" ::= { mib-2 90 }dismanExpressionMIBObjects OBJECT IDENTIFIER ::= { dismanExpressionMIB 1 }expResource OBJECT IDENTIFIER ::= { dismanExpressionMIBObjects 1 }expDefine OBJECT IDENTIFIER ::= { dismanExpressionMIBObjects 2 }expValue OBJECT IDENTIFIER ::= { dismanExpressionMIBObjects 3 }---- Resource Control--Kavasseri & Stewart Standards Track [Page 12]RFC 2982 Distributed Management Expression MIB October 2000expResourceDeltaMinimum OBJECT-TYPE SYNTAX Integer32 (-1 | 1..600) UNITS "seconds" MAX-ACCESS read-write STATUS current DESCRIPTION "The minimum expExpressionDeltaInterval this system will accept. A system may use the larger values of this minimum to lessen the impact of constantly computing deltas. For larger delta sampling intervals the system samples less often and suffers less overhead. This object provides a way to enforce such lower overhead for all expressions created after it is set. The value -1 indicates that expResourceDeltaMinimum is irrelevant as the system will not accept 'deltaValue' as a value for expObjectSampleType. Unless explicitly resource limited, a system's value for this object should be 1, allowing as small as a 1 second interval for ongoing delta sampling. Changing this value will not invalidate an existing setting of expObjectSampleType." ::= { expResource 1 }expResourceDeltaWildcardInstanceMaximum OBJECT-TYPE SYNTAX Unsigned32 UNITS "instances" MAX-ACCESS read-write STATUS current DESCRIPTION "For every instance of a deltaValue object, one dynamic instance entry is needed for holding the instance value from the previous sample, i.e. to maintain state.
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -