IBM Tivoli Monitoring > Version 6.3 Fix Pack 2 > Administrator's Guide > Agent-based services > SNMP alerts > Trap configuration XML specification
IBM Tivoli Monitoring, Version 6.3 Fix Pack 2
Situation element
Use situation elements in a trap configuration XML file to define the trap sent for the situation.
<situation name=”Situation_ID” target=”TrapDest_Name” />The Situation element requires the name and target attributes. Default values are used for any other attributes that are not specified. The * asterisk wildcard can be specified for the situation name or target or both:
- Specify the wildcard for situation name represents all situations. For example the following line sends traps for all defined true situations to the defined TrapDest named trapProbe1:
<situation name=”*” target=”trapProbe1” />Hysteresis mode behavior cannot be specified if a * wildcard is used for situation name.
Specify the wildcard for the target parameter enables sending the situation specified in the situation name field to all defined targets: <situation name=”NT_Disk_Low” target=”*” />
Specify the wildcard for both situation name and target enables the sending of all traps to all defined trap receivers.
Named situations have precedence over wildcard definitions. If a situation definition includes a wildcard and another situation definition names a situation or the target, the first occurrence of the named situation definition is honored. Example: <TrapDest name="MyReceiver" Address="UAHOST1" Version="v1" /> <TrapDest name="OMNIbus1" Address="OMNIbus1" Version="v2" Community="{AES256:keyfile:a}P0hUrmUhCgfFwimS+Q6w+w==" /> <TrapDest name="OMNIbus2" Version="v3" Address="9.42.10.164" SecLevel="authPriv" User="SnmpUser" AuthType="SHA" AuthPassKey="{AES256:keyfile:a}vgpNvf5Vx3XbPj1sKRRvYg==" PrivType="DES" PrivPassKey="{AES256:keyfile:a}OK5YOWvRIkPOw9k4JRy9ag==" /> <situation name="*" target="OMNIbus2" /> <situation name="My_Missing_Process" target="MyReceiver" /> <situation name="NT_AA_Missing_Test" target="OMNIbus1" /> <situation name="NT_AA_Missing_Test" target="OMNIbus2" /> <situation name="NT_ABC_Missing_Test" target="*" />The My_Missing_Process situation sends a trap to MyReceiver instead of OMNIbus2. And NT_ABC_Missing_Test is sent to MyReceiver, OMNIbus1, and OMNIbus2 instead of solely to OMNIbus2 because the situation is defined explicitly rather than using the wildcard.
If a situation is defined more than once, the first occurrence of a situation definition has precedence. Looking again at the example, NT_AA_Missing_Test is sent to OMNIbus1 and not OMNIbus2 because the first occurrence of the definition for the same situation specifies OMNIbus1.
Situation element XML specification
Attribute Description Required Default Name= This is the ID or short name of the situation. Required Target= Specify a previously defined TrapDest. “*” implies send trap to all defined destinations. Required Sev= Specify trap severity. The standard trap severities are:
0 – Cleared
1 – Indeterminate
2 – Warning
3 – Minor
4 – Major
5 – CriticalOptional 2 Cat= Specify trap category. The standard trap categories are:
0 - Threshold
1 – Network Topology
2 – Error
3 – Status
4 – Node Configuration
5 – Application Alert
6 – All Category
7 – Log Only
8 – Map
9 – IgnoreOptional 0 Mode= Used to specify behavior for SNMP trap emission on sampled situations. The standard modes are:
RC – Rising Continuous, whereby traps are sent on each true evaluation of a situation. (Pure events are always RC.) No specific clearing trap will be sent.
HY – Hysteresis, whereby a trap is sent the first time the sampled situation evaluates as true. A clearing trap will be sent once the sampled value no longer meets the criteria of the situation. Hysteresis mode requires the situation be named; not specified with a * wildcard.Optional RC Pred= The situation predicate (formula) is sent in the trap's autoSit-Predicates varbind. The Pred attribute allows you to omit the situation predicate by setting Pred=”N”. This can be useful if you do not care to receive the predicate or if a complex predicate is taking up too much of the trap PDU, and you want more room to send situation attributes in the sitAttributeList varbind. Optional Y Table= Table name of the attribute group. Used with the TrapAttrlist to identify a subset of attributes used to construct the sitAttributeList varbind. Required only if a TrapAttrList is used. TrapAttrList= A comma delimited list of attributes to be included in the sitAttributeList varbind of the traps sent for situation.
Values specified here will override any TrapAttrList values specified in a TrapAttrGroup element for the table that the situation is running against.Optional
Situations for multiple-row attribute groups that include a display item are limited to sending one trap for the first row that evaluates to true, but not for any subsequent rows.
Parent topic:
Trap configuration XML specification