Quick installation(懒人一键安装)
PS: Requirments
wget --no-check-certificate https://github.com/teddysun/across/raw/master/bbr.sh chmod +x bbr.sh ./bbr.sh
# check linux kernel version [[email protected] ~]# uname -a Linux vps-d 4.10.4-1.el7.elrepo.x86_64 #1 SMP Sat Mar 18 12:50:10 EDT 2017 x86_64 x86_64 x86_64 GNU/Linux # check network info [[email protected] ~]# sysctl net.ipv4.tcp_available_congestion_control net.ipv4.tcp_available_congestion_control = bbr cubic reno [[email protected] ~]# sysctl net.ipv4.tcp_congestion_control net.ipv4.tcp_congestion_control = bbr [[email protected] ~]# sysctl net.core.default_qdisc net.core.default_qdisc = fq # check bbr module is load [[email protected] ~]# lsmod | grep bbr tcp_bbr 16384 24
PS: If the kernel version less than 4.12, you need upgrade.
Sample with CentOS 7:
# add repo and install rpm --import https://www.elrepo.org/RPM-GPG-KEY-elrepo.org rpm -Uvh http://www.elrepo.org/elrepo-release-7.0-3.el7.elrepo.noarch.rpm yum --enablerepo=elrepo-kernel install kernel-ml kernel-ml-devel -y # check kernel install rpm -qa | grep kernel # update grub system egrep ^menuentry /etc/grub2.cfg | cut -f 2 -d \' # default 0 # Run by the first core(表示第一个内核设置为默认运行) grub2-set-default 0 # restart reboot
Reference: