如何将 CentOS 6 中的内核升级到最新版本?

如何将 CentOS 6 中的内核升级到最新版本?

它给我带来了问题并且即使在电源循环之后也无法使用最新版本。

[root@server ~]# uname -r
2.6.32-431.1.2.0.1.el6.x86_64
[root@server ~]# cat /boot/grub.conf
cat: /boot/grub.conf: No such file or directory
[root@server ~]# cat /boot/grub/grub.conf
cat: /boot/grub/grub.conf: No such file or directory
[root@server ~]# yum reinstall kernel
Running Transaction
  Installing : kernel-2.6.32-696.20.1.el6.x86_64                                                                                                                                                         1/1
  Verifying  : kernel-2.6.32-696.20.1.el6.x86_64                                                                                                                                                         1/1

Installed:
  kernel.x86_64 0:2.6.32-696.20.1.el6

Complete!
[root@server ~]# less /etc/grub.conf
/etc/grub.conf: No such file or directory
[root@server ~]# poweroff
Broadcast message from root@server
        (/dev/pts/0) at 23:11 ...

The system is going down for power off NOW!
Chloe@xps ~/workspace/
$ ssh root@server
Last login: Thu Feb 15 23:07:40 2018 from 
[root@server ~]# uname -r
2.6.32-431.1.2.0.1.el6.x86_64
[root@server ~]# rpm -q kernel
kernel-2.6.32-573.18.1.el6.x86_64
kernel-2.6.32-504.8.1.el6.x86_64
kernel-2.6.32-431.1.2.0.1.el6.x86_64
kernel-2.6.32-696.20.1.el6.x86_64
[root@server ~]#

CentOS 6

答案1

我列出了所有内核并删除了所有旧的内核。

[root@server ~]# rpm -q kernel
kernel-2.6.32-573.18.1.el6.x86_64
kernel-2.6.32-504.8.1.el6.x86_64
kernel-2.6.32-431.1.2.0.1.el6.x86_64
kernel-2.6.32-696.20.1.el6.x86_64
[root@server ~]# rpm --erase kernel-2.6.32-573.18.1.el6.x86_64 kernel-2.6.32-504.8.1.el6.x86_64 kernel-2.6.32-431.1.2.0.1.el6.x86_64

相关内容