Routine operations for upgrading CentOS system kernel. The current version is CentOS 7 to upgrade to 5.0 kernel.
Check the current kernel version
uname -rImport the key required for elrepo source
rpm --import https://www.elrepo.org/RPM-GPG-KEY-elrepo.orgInstall elrepo source
rpm -Uvh https://www.elrepo.org/elrepo-release-7.0-3.el7.elrepo.noarch.rpmThe above commands may change depending on the centos version. For detailed explanations of steps 2 and 3, you can check the official documentation: http://elrepo.org/tiki/tiki-index.php
Install the latest kernel from yum source
yum -y --enablerepo=elrepo-kernel install kernel-ml-devel kernel-mlSet system startup sequence
First check the system startup items:
grep menuentry /boot/grub2/grub.cfgThen modify which version of the kernel is booted by default:
Note: The current version number (2019-03) is the newly installed 5.0 version number. After that, the kernel version number found above shall prevail.
grub2-set-default 'CentOS Linux (5.0.3-1.el7.elrepo.x86_64) 7 (Core)'Check if it takes effect
grub2-editenv listRestart
init 6Turn on bbr
Modify kernel parameters:
echo "net.core.default_qdisc=fq" >> /etc/sysctl.confecho "net.ipv4.tcp_congestion_control=bbr" >> /etc/sysctl.confSave to take effect
sysctl -pCheck if it takes effect
lsmod |grep bbrshow
tcp_bbr 20480 1That’s it