added files
[bcm963xx.git] / userapps / opensource / net-snmp / man / snmptrap.1.def
1 .\" /***********************************************************
2 .\"     Copyright 1988, 1989 by Carnegie Mellon University
3 .\" 
4 .\"                       All Rights Reserved
5 .\" 
6 .\" Permission to use, copy, modify, and distribute this software and its 
7 .\" documentation for any purpose and without fee is hereby granted, 
8 .\" provided that the above copyright notice appear in all copies and that
9 .\" both that copyright notice and this permission notice appear in 
10 .\" supporting documentation, and that the name of CMU not be
11 .\" used in advertising or publicity pertaining to distribution of the
12 .\" software without specific, written prior permission.  
13 .\" 
14 .\" CMU DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
15 .\" ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
16 .\" CMU BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR
17 .\" ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
18 .\" WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
19 .\" ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
20 .\" SOFTWARE.
21 .\" ******************************************************************/
22 .TH SNMPTRAP 1 "08 Feb 2002" VVERSIONINFO "Net-SNMP"
23 .UC 4
24 .SH NAME
25 snmptrap, snmpinform - sends an SNMP trap to a manager
26 .SH SYNOPSIS
27 .B snmptrap -v 1
28 [COMMON OPTIONS] [-Ci] enterprise-oid agent generic-trap specific-trap uptime [OID TYPE VALUE]...
29 .PP
30 .B snmptrap -v [2c|3]
31 [COMMON OPTIONS] [-Ci] uptime trap-oid [OID TYPE VALUE]...
32 .PP
33 .B snmpinform -v [2c|3]
34 [COMMON OPTIONS] uptime trap-oid [OID TYPE VALUE]...
35 .SH DESCRIPTION
36 .B snmptrap
37 is an SNMP application that uses the SNMP TRAP operation to send
38 information to a network manager.  One or more object identifiers
39 (OIDs) can be given as arguments on the command line.  A type and a
40 value must accompany each object identifier.  Each variable name is
41 given in the format specified in 
42 .IR variables(5) .
43 .PP
44 When invoked as
45 .B snmpinform,
46 or when
47 .B -Ci
48 is added to the command line flags of snmptrap, it sends an
49 INFORM-PDU, expecting a response from the trap receiver,
50 retransmitting if required.  Otherwise it sends an TRAP-PDU or
51 TRAP2-PDU.
52 .PP
53 If any of the required version 1 parameters, 
54 .IR enterprise-oid ,
55 .IR agent ,
56 and
57 .I uptime
58 are specified as empty, it defaults to
59 .IR "1.3.6.1.4.1.3.1.1 (enterprises.cmu.1.1)" ,
60 .IR hostname ,
61 and
62 .I host-uptime
63 respectively.
64 .PP
65 The
66 .I TYPE
67 is a single character, one of:
68 .RS
69 .PD 0
70 .TP 3
71 .B i
72 INTEGER
73 .TP 3
74 .B u
75 UNSIGNED
76 .TP 3
77 .B c
78 COUNTER32
79 .TP 3
80 .B s
81 STRING
82 .TP 3
83 .B x
84 HEX STRING
85 .TP 3
86 .B d
87 DECIMAL STRING
88 .TP 3
89 .B n
90 NULLOBJ
91 .TP 3
92 .B o
93 OBJID
94 .TP 3
95 .B t
96 TIMETICKS
97 .TP 3
98 .B a
99 IPADDRESS
100 .TP 3
101 .B b
102 BITS
103 .PD
104 .RE
105 .PP
106 For example:
107 .PP
108 snmptrap -v 1 -c public manager enterprises.spider test-hub 3 0 '' interfaces.iftable.ifentry.ifindex.1 i 1
109 .PP
110 will send a generic linkUp trap to manager, for interface 1.
111 .SH OPTIONS
112 .B snmptrap
113 takes the common options described in the
114 .I snmpcmd(1) 
115 manual page in
116 addition to the 
117 .B -Ci
118 option described above.
119 .SH SEE ALSO
120 snmpcmd(1), variables(5).