]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - share/man/man4/altq.4
disk(9): Fix a few mandoc related errors
[FreeBSD/FreeBSD.git] / share / man / man4 / altq.4
1 .\"
2 .\" Copyright (c) 2004 Max Laier <mlaier@FreeBSD.org>
3 .\" All rights reserved.
4 .\"
5 .\" Redistribution and use in source and binary forms, with or without
6 .\" modification, are permitted provided that the following conditions
7 .\" are met:
8 .\" 1. Redistributions of source code must retain the above copyright
9 .\"    notice, this list of conditions and the following disclaimer.
10 .\" 2. Redistributions in binary form must reproduce the above copyright
11 .\"    notice, this list of conditions and the following disclaimer in the
12 .\"    documentation and/or other materials provided with the distribution.
13 .\"
14 .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
15 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
16 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
17 .\" ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
18 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
19 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
20 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24 .\" SUCH DAMAGE.
25 .\"
26 .\" $FreeBSD$
27 .\"
28 .Dd October 9, 2019
29 .Dt ALTQ 4
30 .Os
31 .Sh NAME
32 .Nm ALTQ
33 .Nd "alternate queuing of network packets"
34 .Sh SYNOPSIS
35 .Cd options ALTQ
36 .Pp
37 .Cd options ALTQ_CBQ
38 .Cd options ALTQ_CODEL
39 .Cd options ALTQ_RED
40 .Cd options ALTQ_RIO
41 .Cd options ALTQ_HFSC
42 .Cd options ALTQ_CDNR
43 .Cd options ALTQ_PRIQ
44 .Cd options ALTQ_FAIRQ
45 .Sh DESCRIPTION
46 The
47 .Nm
48 system is a framework which provides several disciplines for queuing outgoing
49 network packets.
50 This is done by modifications to the interface packet queues.
51 See
52 .Xr altq 9
53 for details.
54 .Pp
55 The user interface for
56 .Nm
57 is implemented by the
58 .Xr pfctl 8
59 utility, so please refer to the
60 .Xr pfctl 8
61 and the
62 .Xr pf.conf 5
63 man pages for a complete description of the
64 .Nm
65 capabilities and how to use it.
66 .Ss Kernel Options
67 The following options in the kernel configuration file are related to
68 .Nm
69 operation:
70 .Pp
71 .Bl -tag -width ".Dv ALTQ_DEBUG" -compact
72 .It Dv ALTQ
73 Enable
74 .Nm .
75 .It Dv ALTQ_CBQ
76 Build the
77 .Dq "Class Based Queuing"
78 discipline.
79 .It Dv ALTQ_CODEL
80 Build the
81 .Dq "Controlled Delay"
82 discipline.
83 .It Dv ALTQ_RED
84 Build the
85 .Dq "Random Early Detection"
86 extension.
87 .It Dv ALTQ_RIO
88 Build
89 .Dq "Random Early Drop"
90 for input and output.
91 .It Dv ALTQ_HFSC
92 Build the
93 .Dq "Hierarchical Packet Scheduler"
94 discipline.
95 .It Dv ALTQ_CDNR
96 Build the traffic conditioner.
97 This option is meaningless at the moment as the conditioner is not used by
98 any of the available disciplines or consumers.
99 .It Dv ALTQ_PRIQ
100 Build the
101 .Dq "Priority Queuing"
102 discipline.
103 .It Dv ALTQ_FAIRQ
104 Build the
105 .Dq "Fair Queuing"
106 discipline.
107 .It Dv ALTQ_NOPCC
108 Required if the TSC is unusable.
109 .It Dv ALTQ_DEBUG
110 Enable additional debugging facilities.
111 .El
112 .Pp
113 Note that
114 .Nm Ns -disciplines
115 cannot be loaded as kernel modules.
116 In order to use a certain discipline you have to build it into a custom
117 kernel.
118 The
119 .Xr pf 4
120 interface, that is required for the configuration process of
121 .Nm
122 can be loaded as a module.
123 .Sh SUPPORTED DEVICES
124 The driver modifications described in
125 .Xr altq 9
126 are required to use a certain network card with
127 .Nm .
128 They have been applied to the following hardware drivers:
129 .Xr ae 4 ,
130 .Xr age 4 ,
131 .Xr alc 4 ,
132 .Xr ale 4 ,
133 .Xr an 4 ,
134 .Xr aue 4 ,
135 .Xr axe 4 ,
136 .Xr bce 4 ,
137 .Xr bfe 4 ,
138 .Xr bge 4 ,
139 .Xr bxe 4 ,
140 .Xr cas 4 ,
141 .Xr cxgbe 4 ,
142 .Xr dc 4 ,
143 .Xr de 4 ,
144 .Xr ed 4 ,
145 .Xr em 4 ,
146 .Xr ep 4 ,
147 .Xr epair 4 ,
148 .Xr et 4 ,
149 .Xr fxp 4 ,
150 .Xr gem 4 ,
151 .Xr igb 4 ,
152 .Xr ixgbe 4 ,
153 .Xr jme 4 ,
154 .Xr le 4 ,
155 .Xr liquidio 4 ,
156 .Xr msk 4 ,
157 .Xr mxge 4 ,
158 .Xr my 4 ,
159 .Xr nfe 4 ,
160 .Xr nge 4 ,
161 .Xr npe 4 ,
162 .Xr qlxgb 4 ,
163 .Xr re 4 ,
164 .Xr rl 4 ,
165 .Xr sf 4 ,
166 .Xr sge 4 ,
167 .Xr sis 4 ,
168 .Xr sk 4 ,
169 .Xr ste 4 ,
170 .Xr stge 4 ,
171 .Xr ti 4 ,
172 .Xr txp 4 ,
173 .Xr udav 4 ,
174 .Xr vge 4 ,
175 .Xr vr 4 ,
176 .Xr vte 4 ,
177 and
178 .Xr xl 4 .
179 .Pp
180 The
181 .Xr ndis 4
182 framework also has support for
183 .Nm
184 and thus all encapsulated drivers.
185 .Pp
186 The
187 .Xr tun 4
188 and
189 .Xr ng_iface 4
190 pseudo drivers also do support
191 .Nm .
192 .Pp
193 The
194 .Xr vlan 4
195 driver does not directly support
196 .Nm ,
197 but as packets (mbufs) are passed to the underlying interface, a queue
198 can be defined for the underlying interface, and any packets directed
199 to the queue will be processed at the interface level.
200 An example:
201 .Pp
202 .Bd -literal -offset indent
203 altq on igb0 cbq queue { def aq }
204 queue def bandwidth 90% cbq (default borrow)
205 queue aq bandwidth 10Mb cbq
206
207 pass in on igb0.10 proto udp all queue aq keep state
208 .Ed
209 .Sh SEE ALSO
210 .Xr pf 4 ,
211 .Xr pf.conf 5 ,
212 .Xr ipfw 8 ,
213 .Xr pfctl 8 ,
214 .Xr altq 9
215 .Sh HISTORY
216 The
217 .Nm
218 system first appeared in March 1997 and found home in the KAME project
219 (http://www.kame.net).
220 It was imported to
221 .Fx
222 in 5.3 .