Previous Topic: ADDRESS TNG Event Management CommandsNext Topic: UNICMD Command


SNMPTRAP Command

The SNMPTRAP command sends an SNMP trap to the specified host.

This command has the following format:

ADDRESS TNG "SNMPTRAP HOST(HostName|*) [COMMUNITY(CommunityName)]
             GTRAP(GenericTrapNum)
             STRAP(SpecificTrapNum)
             DATA(RexxVar)"
HOST

Specifies the TCP/IP host name (HostName) to which the event is to be sent or * for all host names specified for message forwarding in the Configuration Manager GUI.

COMMUNITY

(Optional) Specifies the community name (CommunityName) under which the trap is to be issued.

Default: public

GTRAP

Specifies the SNMP generic trap type (GenericTrapNum), which can be a value of 0 through 6.

STRAP

Specifies the specific trap number (SpecificTrapNum) to be used when the enterprise-specific GenericTrapNum has a value of 6.

DATA

Specifies the data content of the SNMP trap, which is stored in a REXX variable (RexxVar). The REXX variable must contain the following:

rexxvar.0 = The total number of values supplied (this number must always be a multiple of 3; six are shown below)
rexxvar.1 = OID 1
rexxvar.2 = type 1
rexxvar.3 = value 1
rexxvar.4 = OID 2
rexxvar.5 = type 2
rexxvar.6 = value 2
OID

Specifies he SNMP object identifier for the trap.

type

Specifies the data type of the value that follows. type can be one of the following:

counter

null

opaque

gauge

objectidentifier

opaqueascii

integer

octetstring

timeticks

ipaddress

octetstringascii

 

value

Specifies the value to be sent by the trap.