Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
snmp.h
Go to the documentation of this file.
1 /*
2  * Definitions for MIBs
3  *
4  * Author: Hideaki YOSHIFUJI <[email protected]>
5  */
6 
7 #ifndef _LINUX_SNMP_H
8 #define _LINUX_SNMP_H
9 
10 /* ipstats mib definitions */
11 /*
12  * RFC 1213: MIB-II
13  * RFC 2011 (updates 1213): SNMPv2-MIB-IP
14  * RFC 2863: Interfaces Group MIB
15  * RFC 2465: IPv6 MIB: General Group
16  * draft-ietf-ipv6-rfc2011-update-10.txt: MIB for IP: IP Statistics Tables
17  */
18 enum
19 {
21 /* frequently written fields in fast path, kept in same cache line */
22  IPSTATS_MIB_INPKTS, /* InReceives */
23  IPSTATS_MIB_INOCTETS, /* InOctets */
24  IPSTATS_MIB_INDELIVERS, /* InDelivers */
25  IPSTATS_MIB_OUTFORWDATAGRAMS, /* OutForwDatagrams */
26  IPSTATS_MIB_OUTPKTS, /* OutRequests */
27  IPSTATS_MIB_OUTOCTETS, /* OutOctets */
28 /* other fields */
29  IPSTATS_MIB_INHDRERRORS, /* InHdrErrors */
30  IPSTATS_MIB_INTOOBIGERRORS, /* InTooBigErrors */
31  IPSTATS_MIB_INNOROUTES, /* InNoRoutes */
32  IPSTATS_MIB_INADDRERRORS, /* InAddrErrors */
33  IPSTATS_MIB_INUNKNOWNPROTOS, /* InUnknownProtos */
34  IPSTATS_MIB_INTRUNCATEDPKTS, /* InTruncatedPkts */
35  IPSTATS_MIB_INDISCARDS, /* InDiscards */
36  IPSTATS_MIB_OUTDISCARDS, /* OutDiscards */
37  IPSTATS_MIB_OUTNOROUTES, /* OutNoRoutes */
38  IPSTATS_MIB_REASMTIMEOUT, /* ReasmTimeout */
39  IPSTATS_MIB_REASMREQDS, /* ReasmReqds */
40  IPSTATS_MIB_REASMOKS, /* ReasmOKs */
41  IPSTATS_MIB_REASMFAILS, /* ReasmFails */
42  IPSTATS_MIB_FRAGOKS, /* FragOKs */
43  IPSTATS_MIB_FRAGFAILS, /* FragFails */
44  IPSTATS_MIB_FRAGCREATES, /* FragCreates */
45  IPSTATS_MIB_INMCASTPKTS, /* InMcastPkts */
46  IPSTATS_MIB_OUTMCASTPKTS, /* OutMcastPkts */
47  IPSTATS_MIB_INBCASTPKTS, /* InBcastPkts */
48  IPSTATS_MIB_OUTBCASTPKTS, /* OutBcastPkts */
49  IPSTATS_MIB_INMCASTOCTETS, /* InMcastOctets */
50  IPSTATS_MIB_OUTMCASTOCTETS, /* OutMcastOctets */
51  IPSTATS_MIB_INBCASTOCTETS, /* InBcastOctets */
52  IPSTATS_MIB_OUTBCASTOCTETS, /* OutBcastOctets */
54 };
55 
56 /* icmp mib definitions */
57 /*
58  * RFC 1213: MIB-II ICMP Group
59  * RFC 2011 (updates 1213): SNMPv2 MIB for IP: ICMP group
60  */
61 enum
62 {
64  ICMP_MIB_INMSGS, /* InMsgs */
65  ICMP_MIB_INERRORS, /* InErrors */
66  ICMP_MIB_INDESTUNREACHS, /* InDestUnreachs */
67  ICMP_MIB_INTIMEEXCDS, /* InTimeExcds */
68  ICMP_MIB_INPARMPROBS, /* InParmProbs */
69  ICMP_MIB_INSRCQUENCHS, /* InSrcQuenchs */
70  ICMP_MIB_INREDIRECTS, /* InRedirects */
71  ICMP_MIB_INECHOS, /* InEchos */
72  ICMP_MIB_INECHOREPS, /* InEchoReps */
73  ICMP_MIB_INTIMESTAMPS, /* InTimestamps */
74  ICMP_MIB_INTIMESTAMPREPS, /* InTimestampReps */
75  ICMP_MIB_INADDRMASKS, /* InAddrMasks */
76  ICMP_MIB_INADDRMASKREPS, /* InAddrMaskReps */
77  ICMP_MIB_OUTMSGS, /* OutMsgs */
78  ICMP_MIB_OUTERRORS, /* OutErrors */
79  ICMP_MIB_OUTDESTUNREACHS, /* OutDestUnreachs */
80  ICMP_MIB_OUTTIMEEXCDS, /* OutTimeExcds */
81  ICMP_MIB_OUTPARMPROBS, /* OutParmProbs */
82  ICMP_MIB_OUTSRCQUENCHS, /* OutSrcQuenchs */
83  ICMP_MIB_OUTREDIRECTS, /* OutRedirects */
84  ICMP_MIB_OUTECHOS, /* OutEchos */
85  ICMP_MIB_OUTECHOREPS, /* OutEchoReps */
86  ICMP_MIB_OUTTIMESTAMPS, /* OutTimestamps */
87  ICMP_MIB_OUTTIMESTAMPREPS, /* OutTimestampReps */
88  ICMP_MIB_OUTADDRMASKS, /* OutAddrMasks */
89  ICMP_MIB_OUTADDRMASKREPS, /* OutAddrMaskReps */
91 };
92 
93 #define __ICMPMSG_MIB_MAX 512 /* Out+In for all 8-bit ICMP types */
94 
95 /* icmp6 mib definitions */
96 /*
97  * RFC 2466: ICMPv6-MIB
98  */
99 enum
100 {
102  ICMP6_MIB_INMSGS, /* InMsgs */
103  ICMP6_MIB_INERRORS, /* InErrors */
104  ICMP6_MIB_OUTMSGS, /* OutMsgs */
105  ICMP6_MIB_OUTERRORS, /* OutErrors */
107 };
108 
109 #define __ICMP6MSG_MIB_MAX 512 /* Out+In for all 8-bit ICMPv6 types */
110 
111 /* tcp mib definitions */
112 /*
113  * RFC 1213: MIB-II TCP group
114  * RFC 2012 (updates 1213): SNMPv2-MIB-TCP
115  */
116 enum
117 {
119  TCP_MIB_RTOALGORITHM, /* RtoAlgorithm */
120  TCP_MIB_RTOMIN, /* RtoMin */
121  TCP_MIB_RTOMAX, /* RtoMax */
122  TCP_MIB_MAXCONN, /* MaxConn */
123  TCP_MIB_ACTIVEOPENS, /* ActiveOpens */
124  TCP_MIB_PASSIVEOPENS, /* PassiveOpens */
125  TCP_MIB_ATTEMPTFAILS, /* AttemptFails */
126  TCP_MIB_ESTABRESETS, /* EstabResets */
127  TCP_MIB_CURRESTAB, /* CurrEstab */
128  TCP_MIB_INSEGS, /* InSegs */
129  TCP_MIB_OUTSEGS, /* OutSegs */
130  TCP_MIB_RETRANSSEGS, /* RetransSegs */
131  TCP_MIB_INERRS, /* InErrs */
132  TCP_MIB_OUTRSTS, /* OutRsts */
134 };
135 
136 /* udp mib definitions */
137 /*
138  * RFC 1213: MIB-II UDP group
139  * RFC 2013 (updates 1213): SNMPv2-MIB-UDP
140  */
141 enum
142 {
144  UDP_MIB_INDATAGRAMS, /* InDatagrams */
145  UDP_MIB_NOPORTS, /* NoPorts */
146  UDP_MIB_INERRORS, /* InErrors */
147  UDP_MIB_OUTDATAGRAMS, /* OutDatagrams */
148  UDP_MIB_RCVBUFERRORS, /* RcvbufErrors */
149  UDP_MIB_SNDBUFERRORS, /* SndbufErrors */
151 };
152 
153 /* linux mib definitions */
154 enum
155 {
157  LINUX_MIB_SYNCOOKIESSENT, /* SyncookiesSent */
158  LINUX_MIB_SYNCOOKIESRECV, /* SyncookiesRecv */
159  LINUX_MIB_SYNCOOKIESFAILED, /* SyncookiesFailed */
160  LINUX_MIB_EMBRYONICRSTS, /* EmbryonicRsts */
161  LINUX_MIB_PRUNECALLED, /* PruneCalled */
162  LINUX_MIB_RCVPRUNED, /* RcvPruned */
163  LINUX_MIB_OFOPRUNED, /* OfoPruned */
164  LINUX_MIB_OUTOFWINDOWICMPS, /* OutOfWindowIcmps */
165  LINUX_MIB_LOCKDROPPEDICMPS, /* LockDroppedIcmps */
166  LINUX_MIB_ARPFILTER, /* ArpFilter */
167  LINUX_MIB_TIMEWAITED, /* TimeWaited */
168  LINUX_MIB_TIMEWAITRECYCLED, /* TimeWaitRecycled */
169  LINUX_MIB_TIMEWAITKILLED, /* TimeWaitKilled */
170  LINUX_MIB_PAWSPASSIVEREJECTED, /* PAWSPassiveRejected */
171  LINUX_MIB_PAWSACTIVEREJECTED, /* PAWSActiveRejected */
172  LINUX_MIB_PAWSESTABREJECTED, /* PAWSEstabRejected */
173  LINUX_MIB_DELAYEDACKS, /* DelayedACKs */
174  LINUX_MIB_DELAYEDACKLOCKED, /* DelayedACKLocked */
175  LINUX_MIB_DELAYEDACKLOST, /* DelayedACKLost */
176  LINUX_MIB_LISTENOVERFLOWS, /* ListenOverflows */
177  LINUX_MIB_LISTENDROPS, /* ListenDrops */
178  LINUX_MIB_TCPPREQUEUED, /* TCPPrequeued */
179  LINUX_MIB_TCPDIRECTCOPYFROMBACKLOG, /* TCPDirectCopyFromBacklog */
180  LINUX_MIB_TCPDIRECTCOPYFROMPREQUEUE, /* TCPDirectCopyFromPrequeue */
181  LINUX_MIB_TCPPREQUEUEDROPPED, /* TCPPrequeueDropped */
182  LINUX_MIB_TCPHPHITS, /* TCPHPHits */
183  LINUX_MIB_TCPHPHITSTOUSER, /* TCPHPHitsToUser */
184  LINUX_MIB_TCPPUREACKS, /* TCPPureAcks */
185  LINUX_MIB_TCPHPACKS, /* TCPHPAcks */
186  LINUX_MIB_TCPRENORECOVERY, /* TCPRenoRecovery */
187  LINUX_MIB_TCPSACKRECOVERY, /* TCPSackRecovery */
188  LINUX_MIB_TCPSACKRENEGING, /* TCPSACKReneging */
189  LINUX_MIB_TCPFACKREORDER, /* TCPFACKReorder */
190  LINUX_MIB_TCPSACKREORDER, /* TCPSACKReorder */
191  LINUX_MIB_TCPRENOREORDER, /* TCPRenoReorder */
192  LINUX_MIB_TCPTSREORDER, /* TCPTSReorder */
193  LINUX_MIB_TCPFULLUNDO, /* TCPFullUndo */
194  LINUX_MIB_TCPPARTIALUNDO, /* TCPPartialUndo */
195  LINUX_MIB_TCPDSACKUNDO, /* TCPDSACKUndo */
196  LINUX_MIB_TCPLOSSUNDO, /* TCPLossUndo */
197  LINUX_MIB_TCPLOSTRETRANSMIT, /* TCPLostRetransmit */
198  LINUX_MIB_TCPRENOFAILURES, /* TCPRenoFailures */
199  LINUX_MIB_TCPSACKFAILURES, /* TCPSackFailures */
200  LINUX_MIB_TCPLOSSFAILURES, /* TCPLossFailures */
201  LINUX_MIB_TCPFASTRETRANS, /* TCPFastRetrans */
202  LINUX_MIB_TCPFORWARDRETRANS, /* TCPForwardRetrans */
203  LINUX_MIB_TCPSLOWSTARTRETRANS, /* TCPSlowStartRetrans */
204  LINUX_MIB_TCPTIMEOUTS, /* TCPTimeouts */
205  LINUX_MIB_TCPRENORECOVERYFAIL, /* TCPRenoRecoveryFail */
206  LINUX_MIB_TCPSACKRECOVERYFAIL, /* TCPSackRecoveryFail */
207  LINUX_MIB_TCPSCHEDULERFAILED, /* TCPSchedulerFailed */
208  LINUX_MIB_TCPRCVCOLLAPSED, /* TCPRcvCollapsed */
209  LINUX_MIB_TCPDSACKOLDSENT, /* TCPDSACKOldSent */
210  LINUX_MIB_TCPDSACKOFOSENT, /* TCPDSACKOfoSent */
211  LINUX_MIB_TCPDSACKRECV, /* TCPDSACKRecv */
212  LINUX_MIB_TCPDSACKOFORECV, /* TCPDSACKOfoRecv */
213  LINUX_MIB_TCPABORTONDATA, /* TCPAbortOnData */
214  LINUX_MIB_TCPABORTONCLOSE, /* TCPAbortOnClose */
215  LINUX_MIB_TCPABORTONMEMORY, /* TCPAbortOnMemory */
216  LINUX_MIB_TCPABORTONTIMEOUT, /* TCPAbortOnTimeout */
217  LINUX_MIB_TCPABORTONLINGER, /* TCPAbortOnLinger */
218  LINUX_MIB_TCPABORTFAILED, /* TCPAbortFailed */
219  LINUX_MIB_TCPMEMORYPRESSURES, /* TCPMemoryPressures */
220  LINUX_MIB_TCPSACKDISCARD, /* TCPSACKDiscard */
221  LINUX_MIB_TCPDSACKIGNOREDOLD, /* TCPSACKIgnoredOld */
222  LINUX_MIB_TCPDSACKIGNOREDNOUNDO, /* TCPSACKIgnoredNoUndo */
223  LINUX_MIB_TCPSPURIOUSRTOS, /* TCPSpuriousRTOs */
224  LINUX_MIB_TCPMD5NOTFOUND, /* TCPMD5NotFound */
225  LINUX_MIB_TCPMD5UNEXPECTED, /* TCPMD5Unexpected */
230  LINUX_MIB_TCPMINTTLDROP, /* RFC 5082 */
232  LINUX_MIB_IPRPFILTER, /* IP Reverse Path Filter (rp_filter) */
233  LINUX_MIB_TCPTIMEWAITOVERFLOW, /* TCPTimeWaitOverflow */
234  LINUX_MIB_TCPREQQFULLDOCOOKIES, /* TCPReqQFullDoCookies */
235  LINUX_MIB_TCPREQQFULLDROP, /* TCPReqQFullDrop */
236  LINUX_MIB_TCPRETRANSFAIL, /* TCPRetransFail */
237  LINUX_MIB_TCPRCVCOALESCE, /* TCPRcvCoalesce */
238  LINUX_MIB_TCPOFOQUEUE, /* TCPOFOQueue */
239  LINUX_MIB_TCPOFODROP, /* TCPOFODrop */
240  LINUX_MIB_TCPOFOMERGE, /* TCPOFOMerge */
241  LINUX_MIB_TCPCHALLENGEACK, /* TCPChallengeACK */
242  LINUX_MIB_TCPSYNCHALLENGE, /* TCPSYNChallenge */
243  LINUX_MIB_TCPFASTOPENACTIVE, /* TCPFastOpenActive */
244  LINUX_MIB_TCPFASTOPENPASSIVE, /* TCPFastOpenPassive*/
245  LINUX_MIB_TCPFASTOPENPASSIVEFAIL, /* TCPFastOpenPassiveFail */
246  LINUX_MIB_TCPFASTOPENLISTENOVERFLOW, /* TCPFastOpenListenOverflow */
247  LINUX_MIB_TCPFASTOPENCOOKIEREQD, /* TCPFastOpenCookieReqd */
249 };
250 
251 /* linux Xfrm mib definitions */
252 enum
253 {
255  LINUX_MIB_XFRMINERROR, /* XfrmInError */
256  LINUX_MIB_XFRMINBUFFERERROR, /* XfrmInBufferError */
257  LINUX_MIB_XFRMINHDRERROR, /* XfrmInHdrError */
258  LINUX_MIB_XFRMINNOSTATES, /* XfrmInNoStates */
259  LINUX_MIB_XFRMINSTATEPROTOERROR, /* XfrmInStateProtoError */
260  LINUX_MIB_XFRMINSTATEMODEERROR, /* XfrmInStateModeError */
261  LINUX_MIB_XFRMINSTATESEQERROR, /* XfrmInStateSeqError */
262  LINUX_MIB_XFRMINSTATEEXPIRED, /* XfrmInStateExpired */
263  LINUX_MIB_XFRMINSTATEMISMATCH, /* XfrmInStateMismatch */
264  LINUX_MIB_XFRMINSTATEINVALID, /* XfrmInStateInvalid */
265  LINUX_MIB_XFRMINTMPLMISMATCH, /* XfrmInTmplMismatch */
266  LINUX_MIB_XFRMINNOPOLS, /* XfrmInNoPols */
267  LINUX_MIB_XFRMINPOLBLOCK, /* XfrmInPolBlock */
268  LINUX_MIB_XFRMINPOLERROR, /* XfrmInPolError */
269  LINUX_MIB_XFRMOUTERROR, /* XfrmOutError */
270  LINUX_MIB_XFRMOUTBUNDLEGENERROR, /* XfrmOutBundleGenError */
271  LINUX_MIB_XFRMOUTBUNDLECHECKERROR, /* XfrmOutBundleCheckError */
272  LINUX_MIB_XFRMOUTNOSTATES, /* XfrmOutNoStates */
273  LINUX_MIB_XFRMOUTSTATEPROTOERROR, /* XfrmOutStateProtoError */
274  LINUX_MIB_XFRMOUTSTATEMODEERROR, /* XfrmOutStateModeError */
275  LINUX_MIB_XFRMOUTSTATESEQERROR, /* XfrmOutStateSeqError */
276  LINUX_MIB_XFRMOUTSTATEEXPIRED, /* XfrmOutStateExpired */
277  LINUX_MIB_XFRMOUTPOLBLOCK, /* XfrmOutPolBlock */
278  LINUX_MIB_XFRMOUTPOLDEAD, /* XfrmOutPolDead */
279  LINUX_MIB_XFRMOUTPOLERROR, /* XfrmOutPolError */
280  LINUX_MIB_XFRMFWDHDRERROR, /* XfrmFwdHdrError*/
282 };
283 
284 #endif /* _LINUX_SNMP_H */