发新话题
打印

ubuntu 16升级并开启BBR功能

ubuntu 16升级并开启BBR功能

BBR基本要求:
KVM架构,256M内存,4.9以上内核

1、升级内核
Make sure kernel version is 4.9 or newer:

uname -r
Install Hardware Enablement Stack (HWE) to update kernel automaticly:

apt install --install-recommends linux-generic-hwe-16.04
reboot

以下CentOS、Debian等也适用
2、Enable bbr

modprobe tcp_bbr
echo "tcp_bbr" >> /etc/modules-load.d/modules.conf
echo "net.core.default_qdisc=fq" >> /etc/sysctl.conf
echo "net.ipv4.tcp_congestion_control=bbr" >> /etc/sysctl.conf
sysctl -p

Check if bbr is enabled:

sysctl net.ipv4.tcp_available_congestion_control
sysctl net.ipv4.tcp_congestion_control
lsmod | grep bbr

3、查看当前TCP连接使用BBR的情况
ss -ti

参考:
https://gist.github.com/xterat/cefccb42f7d4b2055368ebb00454861f
https://www.techrepublic.com/article/how-to-enable-tcp-bbr-to-improve-network-speed-on-linux/
https://blog.donbowman.ca/2018/03/25/speedtest-bbr-consistency/
https://superuser.com/questions/992919/how-to-check-the-tcp-congestion-control-algorithm-flavour-in-ubuntu

关闭 Chrome 对 QUIC 协议支持,避免UDP被QoS,提高性能:
http://www.trustcomputing.com.cn/bbs/viewthread.php?tid=1537

高版本Linux快速开启 TCP BBR 实现高效单边加速
http://trustcomputing.com.cn/bbs/viewthread.php?tid=1716

[ 本帖最后由 linda 于 2020-11-20 12:20 编辑 ]

TOP

发新话题