升级CentOS7内核
1.查看当前内核版本
uname -r
返回:3.10.0-693.el7.x86_64
2.导入elrepo源所需的key
rpm --import https://www.elrepo.org/RPM-
GPG-KEY-elrepo.org
3.安装elrepo源
rpm -Uvh https://www.elrepo.org/elrepo-release-7.0-3.el7.elrepo.noarch.rpm
4.安装yum源中最新的内核
yum -y --enablerepo=elrepo-kernel install kernel-ml-devel kernel-ml
5.设置系统启动顺序
1].查看系统启动项:
grep menuentry /boot/grub2/grub.cfg
2].修改启动项为新安装的内核
grub2-set-default 'CentOS Linux (4.17.14-1.el7.elrepo.x86_64) 7 (Core)'
3].查看默认启动的系统版本grub2-editenv list:
grub2-editenv list
saved_entry=CentOS Linux (4.17.14-1.el7.elrepo.x86_64) 7 (Core)
6.重启linux系统
reboot
7.查看内核> 4.9
uname -r
CentOS7开启bbr
1.修改内核参数
cat >>/etc/sysctl.conf << EOF
net.core.default_qdisc=fq
net.ipv4.tcp_congestion_control=bbr
EOF
2.保存生效
sysctl -p
3.查看是否生效
lsmod |grep bbr
tcp_bbr 20480 1
sysctl net.ipv4.tcp_available_congestion_control
net.ipv4.tcp_available_congestion_control = bbr cubic reno
sysctl net.ipv4.tcp_congestion_control
net.ipv4.tcp_congestion_control = bbr
sysctl net.core.default_qdisc
net.core.default_qdisc = fq