[OLD] Enable BBR on Debian Stretch

注意

本文的内容已经合并,失效,或已不具有参考价值,请查看给出的重定向链接。

重定向至: Ubuntu (Debian) 服务器的初始化配置


BBR(Bottleneck Bandwidth and RTT) is a new congestion control algorithm for TCP released by Google. It’s added into Linux kernel since 4.9. Instead of regarding packet loss as the signal of congestion, BBR sequentially probes the bottleneck bandwidth and RTT.

Check if the kernel supports BBR:

1
uname -r    # kernel >= 4.9

After that, use lsmod | grep bbr to test if the output has the word “bbr”. If not:

1
2
modprobe tcp_bbr
echo "tcp_bbr" >> /etc/modules-load.d/modules.conf

Execute these commands:

1
2
3
echo "net.core.default_qdisc=fq" >> /etc/sysctl.conf
echo "net.ipv4.tcp_congestion_control=bbr" >> /etc/sysctl.conf
sysctl -p

Test:

1
2
sysctl net.ipv4.tcp_available_congestion_control
sysctl net.ipv4.tcp_congestion_control
Mastodon