BBR是Google参与开发的TCP拥堵协议.
VVR可以优化TCP连接,防止TCP拥堵,这是个神器!
教程已经有了,转自hostloc
1:首先yum update -y更新到最新CentOS 7.3 1611
cat /etc/redhat-release
CentOS Linux release 7.3.1611 (Core)
2: 安装elrepo内核
rpm --import https://www.elrepo.org/RPM-GPG-KEY-elrepo.org
rpm -Uvh http://www.elrepo.org/elrepo-release-7.0-2.el7.elrepo.noarch.rpm
然后先rpm -qa |grep kernel
先卸载旧的kernel-headers,kernel-tools, kernel-tools-libs,只保留内核,
然后yum --enablerepo=elrepo-kernel install kernel-ml
就会安装elrepo正式版4.9内核,跟着再安装kernel-ml-headers kernel-ml-tools kernel-ml-tools-libs,
然后
awk -F\' '$1=="menuentry " {print $2}' /etc/grub2.cfg
看看内核启动顺序,然后更新引导
grub2-set-default 0 grub2-mkconfig -o /boot/grub2/grub.cfg grub2-mkconfig -o /boot/efi/EFI/centos/grub.cfg
把kernel-ml 4.9设为默认,重启
3:跟着vim /etc/sysctl.conf
加两行:
net.core.default_qdisc = fq
net.ipv4.tcp_congestion_control = bbr
sysctl -p生效,就ok了。
sed -i '/net.core.default_qdisc/d' /etc/sysctl.conf sed -i '/net.ipv4.tcp_congestion_control/d' /etc/sysctl.conf echo "net.core.default_qdisc = fq" >> /etc/sysctl.conf echo "net.ipv4.tcp_congestion_control = bbr" >> /etc/sysctl.conf sysctl -p
4 检查BBR是否成功
sysctl net.ipv4.tcp_available_congestion_control sysctl -n net.ipv4.tcp_congestion_control lsmod | grep bbr
执行命令,是否看到BBR提示
来源1: http://www.hostloc.com/forum.php?mod=viewthread&tid=343387
BBR一键安装:
wget --no-check-certificate https://github.com/52fancy/GooGle-BBR/raw/master/BBR.sh && sh BBR.sh
来源2: http://www.hostloc.com/forum.php?mod=viewthread&tid=342622
大佬的BBR一键安装包
wget --no-check-certificate https://github.com/teddysun/across/raw/master/bbr.sh && chmod +x bbr.sh && ./bbr.sh
魔改BBR, 暴力提速(注意:流量消耗激增)
https://github.com/xratzh/CBBR
BBR-PLUS, 大神修正的BBR,只支持CENTOS7
wget "https://github.com/cx9208/bbrplus/raw/master/ok_bbrplus_centos.sh" && chmod +x ok_bbrplus_centos.sh && ./ok_bbrplus_centos.sh
4in1脚本
wget "https://github.com/cx9208/Linux-NetSpeed/raw/master/tcp.sh" && chmod +x tcp.sh && ./tcp.sh
debian9手动安装bbrplus
https://github.com/ylx2016/kernel
不卸载内核
wget -N --no-check-certificate "https://raw.githubusercontent.com/ylx2016/Linux-NetSpeed/2020.2.3/tcpx.sh" && chmod +x tcpx.sh && ./tcpx.sh
卸载内核
wget -N --no-check-certificate "https://raw.githubusercontent.com/ylx2016/Linux-NetSpeed/2020.2.3/tcp.sh" && chmod +x tcp.sh && ./tcp.sh
wget https://github.com/ylx2016/kernel/releases/download/4.14.168bbrplus/linux-headers-4.14.168-bbrplus_4.14.168-bbrplus-1-d9_amd64.deb wget https://github.com/ylx2016/kernel/releases/download/4.14.168bbrplus/linux-image-4.14.168-bbrplus_4.14.168-bbrplus-1-d9_amd64.deb wget https://github.com/ylx2016/kernel/releases/download/4.14.168bbrplus/linux-libc-dev_4.14.168-bbrplus-1-d9_amd64.deb dpkg -i *.deb update-grub sed -i '/net.core.default_qdisc/d' /etc/sysctl.conf sed -i '/net.ipv4.tcp_congestion_control/d' /etc/sysctl.conf echo "net.core.default_qdisc=fq" >> /etc/sysctl.conf echo "net.ipv4.tcp_congestion_control=bbrplus" >> /etc/sysctl.conf sysctl -p
centos7手动安装bbrplus
https://www.hostloc.com/thread-588719-1-1.html
此处评论已关闭