Each incoming trap is identified by three fields: Enterprise OID, generic trap number, and specific trap number. Some SNMP agents send traps with the same combination of OID, generic, and specific trap numbers but for different reasons. When this occurs, the only way to differentiate the meaning of the trap is to examine the varbinds. You can use the $V<n>-[<tag>]$ variable to map varbind values to different text strings.

The format of the Map parameter when using tags is as follows:

 Map:  {
   V<n-tag1>
    <value_a>= <string1>
    <value_b>= <string2>
    default= <string3>
   }
   {
   V<n-tag2>
    <value_a>= <string4>
    <value_b>= <string5>
    default=
   }
   }
   V<n-tag3>
    <value_a>= <string6>
    <value_b>= <string7>
    default=

The following example defines two $V<n>-[<tag>]$ variables, one for substitution of ClassName and another for substitution of EventName:

BEGIN_TRAP .1.3.6.1.4.1.546.1.1 6 
 ClassName:    $V2-class$
 EventName:    $V2-event$
.
.
.

The mapping defines when to map the appropriate tags to the varbinds.

.
.
.
 Map:  {
   V2-class
   .1.3.6.1.4.1.546.1.1.7.9.30.0= Memory
   .1.3.6.1.4.1.546.1.1.7.9.2.0= Processor
   default=Host
   }
   {
   V2-event
   .1.3.6.1.4.1.546.1.1.7.9.30.0= NotEnoughMem
   .1.3.6.1.4.1.546.1.1.7.9.2.0= HighUtilization
   default= TrapReceived
   }

If the incoming trap has a Varbind 2 value of .1.3.6.1.4.1.546.1.1.7.9.30.0, then Memory is used for the ClassName and NotEnoughMem is used for the EventName. If the incoming trap has a Varbind 2 value of .1.3.6.1.4.1.546.1.1.7.9.2.0, then Processor is used for the ClassName and HighUtilization is used for the EventName. The default, Host, is used for the ClassName and the default, TrapReceived, is used for the EventName for incoming traps with any other Varbind 2 values. If a default is not specified, the original value for the Varbind 2 is returned.