第一更新引导列表
sudo grub2-mkconfig -o /boot/efi/EFI/redhat/grub.cfg
第二查看可引导内核
cat /boot/efi/EFI/redhat/grub.cfg | grep menuentry
第三设置默认引导内核
grub2-set-default 'Red Hat Enterprise Linux Server (4.14.9) 7.4 (Maipo)'
2018-03-09更新
sudo grub2-mkconfig -o /boot/efi/EFI/redhat/grub.cfg
cat /boot/efi/EFI/redhat/grub.cfg | grep menuentry
grub2-set-default 'Red Hat Enterprise Linux Server (4.15.0-rc2+) 7.5 (Maipo)'
2018-03-21更新
sudo grub2-mkconfig -o /boot/efi/EFI/redhat/grub.cfg
cat /boot/efi/EFI/redhat/grub.cfg | grep menuentry
grub2-set-default 'Red Hat Enterprise Linux Server (4.16.0-rc6) 7.5 (Maipo)'
2018-03-29更新
sudo grub2-mkconfig -o /boot/efi/EFI/redhat/grub.cfg
cat /boot/efi/EFI/redhat/grub.cfg | grep menuentry
grub2-set-default 'Red Hat Enterprise Linux Server (4.15.14) 7.5 (Maipo)'
2018-04-04更新
sudo grub2-mkconfig -o /boot/efi/EFI/redhat/grub.cfg
cat /boot/efi/EFI/redhat/grub.cfg | grep menuentry
grub2-set-default 'Red Hat Enterprise Linux Server (4.16.0) 7.5 (Maipo)'
注:
①本文测试环境为台电X98 air 3g 安装Redhat7,独立EFI分区
②查询系统中全部的内核: [root@localhost dx]# rpm -qa | grep kernel
③内核编译简易步骤
sudo make menuconfig
sudo make -j8
sudo make headers_install
sudo make modules_install
sudo make install