xref: /freebsd/share/man/man4/tcp_bbr.4 (revision e0c4386e7e71d93b0edc0c8fa156263fc4a8b0b6)
1.\"
2.\" Copyright (c) 2020, Gordon Bergling <gbe@FreeBSD.org>
3.\"
4.\" Redistribution and use in source and binary forms, with or without
5.\" modification, are permitted provided that the following conditions
6.\" are met:
7.\" 1. Redistributions of source code must retain the above copyright
8.\"    notice, this list of conditions and the following disclaimer.
9.\" 2. Redistributions in binary form must reproduce the above copyright
10.\"    notice, this list of conditions and the following disclaimer in the
11.\"    documentation and/or other materials provided with the distribution.
12.\"
13.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
14.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
15.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
16.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR
17.\" ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
18.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
19.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
20.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
21.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
22.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
23.\" SUCH DAMAGE.
24.\"
25.Dd December 17, 2023
26.Dt TCP_BBR 4
27.Os
28.Sh NAME
29.Nm tcp_bbr
30.Nd TCP Bottleneck Bandwidth and Round-Trip Time Algorithm
31.Sh SYNOPSIS
32To load the driver as a module at boot time, place the following line in
33.Xr loader.conf 5 :
34.Bd -literal -offset indent
35tcp_bbr_load="YES"
36.Ed
37.Pp
38To enable the TCP stack you must place the following line in the
39.Xr sysctl.conf 5 :
40.Bd -literal -offset indent
41net.inet.tcp.functions_default=bbr
42.Ed
43.Sh DESCRIPTION
44Bottleneck bandwidth and round-trip time (BBR) is a congestion control algorithm which
45seeks high throughput with a small queue by probing BW and RTT.
46It is a round-up redesign of congestion control, which is not loss-based, delay-based,
47ECN-based or AIMD-based.
48.Pp
49The core design of BBR is about creating a model graph of the network path by
50estimating the maximum BW and minimum RTT on each ACK.
51.Sh MIB Variables
52The algorithm exposes the following scopes in the
53.Va net.inet.tcp.bbr
54branch of the
55.Xr sysctl 3
56MIB:
57.Bl -tag -width ".Va exp_backoff_scale"
58.It Va cwnd
59Cwnd controls, for example "target cwnd rtt measurement" and "BBR initial window".
60.It Va measure
61Measurement controls.
62.It Va pacing
63Connection pacing controls.
64.It Va policer
65Policer controls, for example "false detection threshold" and "loss threshold".
66.It Va probertt
67Probe RTT controls.
68.It Va startup
69Startup controls.
70.It Va states
71State controls.
72.It Va timeout
73Time out controls.
74.El
75.Pp
76Besides the variables within the above scopes the following
77variables are also exposed in the
78.Va net.inet.tcp.bbr
79branch:
80.Bl -tag -width ".Va exp_backoff_scale"
81.It Va clrlost
82Clear lost counters.
83.It Va software_pacing
84Total number of software paced flows.
85.It Va hdwr_pacing
86Total number of hardware paced flows.
87.It Va enob_no_hdwr_pacing
88Total number of enobufs for non-hardware paced flows.
89.It Va enob_hdwr_pacing
90Total number of enobufs for hardware paced flows.
91.It Va rtt_tlp_thresh
92What divisor for TLP rtt/retran will be added (1=rtt, 2=1/2 rtt etc).
93.It Va reorder_fade
94Does reorder detection fade, if so how many ms (0 means never).
95.It Va reorder_thresh
96What factor for rack will be added when seeing reordering (shift right).
97.It Va bb_verbose
98Should BBR black box logging be verbose.
99.It Va sblklimit
100When do we start ignoring small sack blocks.
101.It Va resend_use_tso
102Can resends use TSO?
103.It Va data_after_close
104Do we hold off sending a RST until all pending data is ack'd.
105.It Va kill_paceout
106When we hit this many errors in a row, kill the session?
107.It Va error_paceout
108When we hit an error what is the min to pace out in usec's?
109.It Va cheat_rxt
110Do we burst 1ms between sends on retransmissions (like rack)?
111.It Va minrto
112Minimum RTO in ms.
113.El
114.Sh SEE ALSO
115.Xr cc_chd 4 ,
116.Xr cc_cubic 4 ,
117.Xr cc_hd 4 ,
118.Xr cc_htcp 4 ,
119.Xr cc_newreno 4 ,
120.Xr cc_vegas 4 ,
121.Xr h_ertt 4 ,
122.Xr mod_cc 4 ,
123.Xr tcp 4 ,
124.Xr tcp_rack 4 ,
125.Xr mod_cc 9
126.Rs
127.%A "Neal Cardwell"
128.%A "Yuchung Cheng"
129.%A "Stephen Gunn"
130.%A "Soheil Hassas Yeganeh"
131.%A "Van Jacobson"
132.%T "BBR: Congestion-Based Congestion Control"
133.%J "ACM Queue, Vol. 14"
134.%D "September / October 2016"
135.Re
136.Rs
137.%A "Dominik Scholz"
138.%A "Benedikt Jaeger"
139.%A "Lukas Schwaighofer"
140.%A "Daniel Raumer"
141.%A "Fabien Geyer"
142.%A "Georg Carle"
143.%T "Towards a Deeper Understanding of TCP BBR Congestion Control"
144.%J "IFIP Networking 2018"
145.%D "May 2018"
146.%U "http://www.net.in.tum.de/fileadmin/bibtex/publications/papers/IFIP-Networking-2018-TCP-BBR.pdf"
147.Re
148.Sh HISTORY
149The
150.Nm
151congestion control module first appeared in
152.Fx 13.0 .
153.Sh AUTHORS
154.An -nosplit
155The
156.Nm
157congestion control module was written by
158.An Randall Stewart Aq Mt rrs@FreeBSD.org
159and sponsored by Netflix, Inc.
160This manual page was written by
161.An Gordon Bergling Aq Mt gbe@FreeBSD.org .
162