centos 安装 谷歌BBR

使用root用户登录,运行以下命令:
wget --no-check-certificate https://github.com/teddysun/across/raw/master/bbr.sh && chmod +x bbr.sh && ./bbr.sh
(执行过程中,在最后一步不要重启机器)

内核升级后,重启前,执行:
1) 创建force-vitio_blk-to-ensure-boot.conf
# echo 'add_drivers+="virtio_blk"' >/etc/dracut.conf.d/force-vitio_blk-to-ensure-boot.conf
2) 切换目录
# cd /boot
3) 重新编译生成initramfs
# dracut -f /boot/initramfs-4.9.1-1.el6.elrepo.x86_64.img 4.9.1-1.el6.elrepo.x86_64
4) 重启
# reboot

检验:

lsmod | grep bbr
返回值有 tcp_bbr 模块即说明 bbr 已启动。注意:并不是所有的 VPS 都会有此返回值,若没有也属正常。
原文地址:https://www.cnblogs.com/yunweis/p/8135282.html