修改sysctl.conf配置文件:
echo "net.core.default_qdisc=fq" >> /etc/sysctl.conf
echo "net.ipv4.tcp_congestion_control=bbr" >> /etc/sysctl.conf
保存sysctl并使之生效:
sysctl -p
验证是否生效(方法一):
sysctl net.ipv4.tcp_available_congestion_control
提示如下则表明bbr生效:
sysctl net.ipv4.tcp_available_congestion_control
net.ipv4.tcp_available_congestion_control = bbr cubic reno
验证是否生效(方法二):
lsmod | grep bbr
提示如下则表明bbr生效(16315数字各不同):
tcp_bbr 16315 1