联系我们:416326801#qq.com(#改成@)

img1

Linux升级内核kernel

465 Views 标签: Linux yum kernel

uname -r
yum groupinstall "Development Tools" -y
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 --disablerepo="*" --enablerepo="elrepo-kernel"list available
yum --disablerepo="*" --enablerepo="elrepo-kernel" list available
yum --enablerepo=elrepo-kernel install kernel-lt
awk -F\' '$1=="menuentry " {print $2}' /etc/grub2.cfg 
grub2-set-default0
reboot
uname -r

启动项

[root@localhost ~]# awk -F\' '$1=="menuentry " {print $2}' /etc/grub2.cfg
CentOS Linux (4.4.112-1.el7.elrepo.x86_64) 7 (Core)
CentOS Linux (3.10.0-514.10.2.el7.x86_64) 7 (Core)
CentOS Linux (3.10.0-514.el7.x86_64) 7 (Core)
CentOS Linux (0-rescue-5bb255f67f7f40dd8f4af646ea15c6b5) 7 (Core)

如果觉得我的文章对您有用,打赏一下呗.

wxpay.png