making linux tcp fast
play

Making Linux TCP Fast Yuchung Cheng Neal Cardwell 1 netdev 1.2 - PowerPoint PPT Presentation

Making Linux TCP Fast Yuchung Cheng Neal Cardwell 1 netdev 1.2 Tokyo, October, 2016 Once upon a time, there was a TCP ACK... Here is the a story of what happened next... 2 RACK: detect losses by packets send time Monitors the delivery


  1. Making Linux TCP Fast Yuchung Cheng Neal Cardwell 1 netdev 1.2 Tokyo, October, 2016

  2. Once upon a time, there was a TCP ACK... Here is the a story of what happened next... 2

  3. RACK: detect losses by packets’ send time Monitors the delivery process of every (re)transmission. E.x. Sent packets P1 and P2 Receives a SACK of P2 => P1 is lost if sent more than $RTT + $reo_wnd ago 1 Reduce timeouts in Disorder state by 80% on Google.com 1 RACK draft-ietf-tcpm-rack-00 since Linux 4.4 3

  4. congestion control: how fast to send? 4

  5. Congestion and bottlenecks 5

  6. Congestion and bottlenecks Delivery rate 6 BDP amount in flight BDP + BufSize

  7. RTT Delivery rate 7 BDP amount in flight BDP + BufSize

  8. CUBIC / Reno RTT Delivery rate 8 BDP amount in flight BDP + BufSize

  9. Optimal� max BW and min RTT (Gail & Kleinrock. 1981) RTT Delivery rate 9 BDP amount in flight BDP + BufSize

  10. Estimating optimal point (max BW, min RTT) BDP = (max BW) * (min RTT) RTT Est min RTT = windowed min of RTT samples Delivery rate Est max BW = windowed max of BW samples 10 BDP amount in flight BDP + BufSize

  11. But to see both max BW and min RTT, must probe on both sides of BDP... Only min RTT is RTT visible Delivery rate Only max BW is visible 11 BDP amount in flight BDP + BufSize

  12. One way to stay near (max BW, min RTT) point: Model network, update max BW and min RTT estimates on each ACK Control sending based on the model, to... Probe both max BW and min RTT, to feed the model samples Pace near estimated BW, to reduce queues and loss Vary pacing rate to keep inflight near BDP (for full pipe but small queue) That's BBR congestion control (code in Linux v4.9� paper� ACM Queue, Oct 2016) BBR = B ottleneck B andwidth and R ound-trip propagation time BBR seeks high tput with small queue by probing BW and RTT sequentially 12

  13. BBR: model-based walk toward max BW, min RTT optimal operating point 13 Confidential + Proprietary

  14. STARTUP: exponential BW search 14 Confidential + Proprietary

  15. DRAIN: drain the queue created during startup 15 Confidential + Proprietary

  16. PROBE_BW: explore max BW, drain queue, cruise 16 Confidential + Proprietary

  17. PROBE_RTT briefly if min RTT filter expires (=10s)* minimal packets in flight for max(0.2s, 1 round trip) [*] if continuously sending 17 Confidential + Proprietary

  18. Packet scheduling: when to send? 18

  19. TCP TSO autosizing ? TCP Small Queues (TSQ) Pacing fq Fair queuing NIC link 19

  20. Performance results... 20

  21. Fully use bandwidth, despite high loss BBR vs CUBIC� synthetic bulk TCP test with 1 flow, bottleneck_bw 100Mbps, RTT 100ms 21

  22. Low queue delay, despite bloated buffers BBR vs CUBIC� synthetic bulk TCP test with 8 flows, bottleneck_bw=128kbps, RTT=40ms 22

  23. BBR is 2-20x faster on Google WAN BBR used for all TCP on Google B4 ● Most BBR flows so far rwin-limited ● max RWIN here was 8MB ○ (tcp_rmem[2]) 10 Gbps x 100ms = 125MB BDP ○ after lifting rwin limit� ● BBR 133x faster than CUBIC ○ 23

  24. Conclusion Algorithms and architecture in Linux TCP have evolved Maximizing BW, minimizing queue, and one-RTT recovery (BBR, RACK) ● Based on groundwork of a high-performance packet scheduler ● (fq/pacing/tsq/tso-autosizing) Orders of magnitude higher bandwidth and lower latency ● Next� Google, YouTube, and... the Internet? Help us make them better! https://groups.google.com/forum/#!forum/bbr-dev ● 24

  25. Backup slides... 26

  26. BBR convergence dynamics bw = 100 Mbit/sec path rtt = 10ms Converge by sync'd PROBE_RTT + randomized cycling phases in PROBE_BW Queue (RTT) reduction is observed by every (active) flow ● Elephants yield more (multiplicative decrease) to let mice grow ● Confidential + Proprietary

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend