Entering Commands For The Trap Receiver Program; Trap Receiver Flags; Setting Up An Snmp Trap Service; Snmp_Traprcv Command Flags - Compaq TCP/IP Services for OpenVMS Programming And Reference Manual

Tcp/ip services for openvms
Table of Contents

Advertisement

Using the SNMP Utilities
4.2 Using the Trap Sender and Trap Receiver Programs
enterprise - 1.2.3
agent address - 6.20.208.53
trap type - Enterprise-specific (6)
enterprise-specific value - (33)
timeticks - 100

4.2.2 Entering Commands for the Trap Receiver Program

The trap receiver program lets you listen for, receive, and display SNMP trap
messages. Until interrupted, the program continues to listen on the specified
port.
If you enter commands using the default port number or another privileged port
number, you must run the program from a privileged account.
To run the trap receiver program, do the following:
1. Define a foreign command for the program:
$ snmp_traprcv == "$SYS$SYSTEM:TCPIP$SNMP_TRAPRCV"
Alternatively, you can run SYS$MANAGER:TCPIP$DEFINE_
COMMANDS.COM to define all the foreign commands available with TCP/IP
Services.
2. Enter a command using the following format:
snmp_traprcv [-d] [-tcp] [-p port]

4.2.2.1 Trap Receiver Flags

Table 4–6 describes the
Table 4–6 snmp_traprcv Command Flags
Flag
-d
-p port
-tcp

4.2.2.2 Setting Up an SNMP Trap Service

To set up an SNMP trap service for use with the trap receiver program, enter a
management command in the following format:
SET SERVICE SNMP-TRAP /PROTOCOL=UDP /USER_NAME=TCPIP$SNMP
/PROCESS_NAME=TCPIP$SNMP-TRAP /FILE=TCPIP$SYSTEM:TCPIP$SNMP-TRAP.COM
In this command, port 170 is used as an alternative for port 162, and traps that
are received on port 162 are ignored.
If you omit the /PROTOCOL qualifier or you use /PROTOCOL=TCP, the service
uses the TCP transport. In this case, when you enter a command to run the trap
receiver program, you must include the
With the SNMP trap service in place, the trap receiver program queries the
service for the port number instead of using the default port 162. If you specify
a privileged port number (less than 1024) with the /PORT qualifier, make sure
you install the trap receiver program with privileges, or run the program from an
4–12 Using the SNMP Utilities
snmp_traprcv
flags.
Description
Displays a hexadecimal and formatted dump of the received packet.
Specifies the port number on the local host on which to listen for trap
messages. The default is 162.
Listens on the TCP port instead of the UDP (default) port. Reads only
a single PDU on an established connection, which is similar to the
behavior using UDP.
-tcp
flag.

Advertisement

Table of Contents
loading

Table of Contents