Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: typo fix

BBR is a new algorithm for TCP Congestion Control. It was tested in Google's data center networks as well as on some of their public-facing Web servers including Google.com and YouTube. It strives to optimize both throughput and latency/RTT by estimating the bottleneck bandwidth and RTT to compute a pacing rate. One goal — one that sets it apart from most traditional TCP variants — is to avoid filling up the bottleneck buffer, which might induce Bufferbloat.

The BBR team developed an improved version, BBRv2, to address some shortcomings with the original version of BBR. BBRv2 should no longer starve instances of other TCP implementations (e.g. Reno or CUBIC) sharing the same bottleneck, or induce high loss rates when the queue at the bottleneck is limited. BBRv2 also supports some forms of ECN signals; not the "classical" version where each "congestion experienced" bit is supposed to be interpreted like a lost packet for congestion control, but the newer "DCTCP-style" ECN variants, including Prague TCP/L4S. Unlike BBR"v1", BBRv2 interprets loss as a signal, and tries to respect a (configurable) target loss rate ceiling.

The use of BBR is not limited to TCP anymore. It is used on a large scale in QUIC (see under "implementations" below), and it has been proposed as CCID (Congestion Control ID) 5 in DCCP, the Datagram Congestion Control Protocol.

Operation

A description of the BBR (v1) algorithm was published in the September/October 2016 issue of ACM Queue. An implementation in the Linux kernel has been proposed as a patch. Dave Taht posted a preliminary evaluation ("a quick look...") on his blog. An good description of the BBR's motivation and approach is included in the proposed kernel patch (see below).

...

Code Block
Here is a state transition diagram for BBR:


            |
            V
   +---> STARTUP  ----+
   |        |         |
   |        V         |
   |      DRAIN   ----+
   |        |         |
   |        V         |
   +---> PROBE_BW ----+
   |      ^    |      |
   |      |    |      |
   |      +----+      |
   |                  |
   +---- PROBE_RTT <--+

 A BBR flow starts in STARTUP, and ramps up its sending rate quickly.
 When it estimates the pipe is full, it enters DRAIN to drain the queue.
 In steady state a BBR flow only uses PROBE_BW and PROBE_RTT.
 A long-lived BBR flow spends the vast majority of its time remaining
 (repeatedly) in PROBE_BW, fully probing and utilizing the pipe's bandwidth
 in a fair manner, with a small, bounded queue. If a flow has been
 continuously sending for the entire min_rtt window, and hasn't seen an RTT
 sample that matches or decreases its min_rtt estimate for 10 seconds, then
 it briefly enters PROBE_RTT to cut inflight to a minimum value to re-probe
 the path's two-way propagation delay (min_rtt). When exiting PROBE_RTT, if
 we estimated that we reached the full bw of the pipe then we enter PROBE_BW;
 otherwise we enter STARTUP to try to fill the pipe.

BBRv2 is based on the same state machine. The new behavior is illustrated in slides 20–26 of the IETF-104 presentation, see under "References" below.

Implementation

Linux kernel TCP implementation

...

BBR exports its bandwidth and RTT estimates using the getsockopt(TCP_CC_INFO) interface, see struct tcp_bbr_info . User-space applications can use this information as hints for adapting their use of a given connection, e.g. by selecting appropriate audio or video encodings.

BBRv2

An "alpha/preview" version of BBRv2 is available under a "v2alpha" branch on GitHub. An implementation of BBRv2 for QUIC is included in the Chromium source as bbr2_sender.cc and bbr2_sender.h.

Other implementations

*BSD

Netflix has contributed According to the BBR update from IETF 99 (see reference below), Netflix is working on an implementation of BBR for FreeBSD.to FreeBSD. See the main/sys/netinet/tcp_stacks/bbr.c source file and the commented commit by Randall Stewart from September 2019.

Microsoft Windows

Recent Insider Builds for Windows 11 contain an experimental knob to enable BBR in TCP, according to a presentation at the ICCRG meeting at IETF 112.

BBR in QUIC

BBR BBR has also been implemented for QUIC (including BBRv2, see above), and is in active use on Google's servers. Source code can be found in the congestion_control part of Google's QUICHE project. This is also used by Chromium, the open-source upstream project for Google Chrome. The main logic can be found in the tcp_sender.{cc,h} files.

Cloudflare has an independent implementation of QUIC and HTTP/3, written in Rust. Somewhat confusingly, this is also called QUICHE and can be found on GitHub under cloudflare/quiche. BBR support has been announced as possible future work in a blog post about CUBIC and HyStart++ Support in quiche, but, as of November 2021, hasn't appeared in the official source tree yet.

Other

Mark Claypool has written an implementation of BBR for ns-3, a popular network simulator.

A simplified BBR implementation has been written as part of the Congestion Control Plane (CCP) work at Stanford.

History/Related Work

There is another instance of "BBR TCP", namely Bufferbloat Resistant TCP proposed by Michael Fitz Nowlan in his 2014 Ph.D. thesis (Yale library catalog entry, PDF). It shares the basic goals of (Google's) BBR TCP, namely to detect bottleneck rate and to avoid bufferbloat. But it uses a delay-based measurement approach rather than direct measurement of the amount of ACKed data per time, and doesn't seem to make use of pacing. Despite these differences, the link between the two BBR TCPs seems more than just a coincidental acronym collision: Fitz Nowlan is acknowledged in the Queue/CACM papers, and conversely acknowledges several of the "Google" BBR authors in his thesis.

References

...

  • BBR Congestion Control: IETF 100 Update: BBR in shallow buffers, N.l Cardwell, Y. Cheng, C. S. Gunn, S. Hassas Yeganeh, I. Swett, J. Iyengar, V. Vasiliev, V. Jacobson, Presentation to ICCRG, Singapore, Nov 2017 (videoslides)
  • BBR Congestion Control Work at Google: IETF 101 Update, N. Cardwell, Y. Cheng, C. S. Gunn, S. Hassas Yeganeh, I. Swett, J. Iyengar, V. Vasiliev, P. Jha, Y. Seung, V. Jacobson, Presentation to ICCRG, London, March 2018 (videoslides)
  • BBR Congestion Control Work at Google: IETF 102 Update, N. Cardwell, Y. Cheng, C. S. Gunn, S. Hassas Yeganeh, I. Swett, J. Iyengar, V. Vasiliev, P. Jha, Y. Seung, K. Yang, M. Mathis, V. Jacobson, Presentation to ICCRG, Montréal, July 2018 (videoslides)
  • BBR Congestion Control: IETF 102 Update: BBR Startup, Ian Swett, Montréal, July 2018 (videoslides)
  • BBRx: Extending BBR for Customized TCP Performance, Jae Won Chung, Feng Li, Beomjun Kim, NetDev 0x12, Montréal, July 2018 (abstract, video, slides, paper)
  • BBR v2: A Model-based Congestion Control, N. Cardwell, Y. Cheng, S. Hassas Yeganeh, I. Swett, V. Vasiliev, P. Jha, Y. Seung, M. Mathis, V. Jacobson, Presentation to ICCRG at IETF 104, Prague, March 2019 (slides, video)
  • BBR v2: A Model-based Congestion Control—IETF 105 Update, N. Cardwell, Y. Cheng, S. Hassas Yeganeh, P. Jha, Y. Seung, I. Swett, V. Vasiliev, Bin Wu, M. Mathis, V. Jacobson, Presentation to ICCRG, Montréal, July 2019 (slides)
  • Understanding of BBRv2: Evaluation and Comparison With BBRv1 Congestion Control Algorithm, Y. Song, G. Kim, I. Mahmud, W. Seo, Y. Cho, IEEE Access (Vol. 9), February 2021
  • draft-romo-iccrg-ccid5-00.html, Profile for Datagram Congestion Control Protocol (DCCP) Congestion Control ID 5, N. Romo, J. Kim, M. Amend, October 2021 (work in progress)