安装系统后发现该国产服务器不支持oracle linux uek内核,只得切换到redhat内核。
[root@db1 ~]#  uname -a
 Linux db1 5.4.17-2011.6.2.el7uek.x86_64 #2 SMP Thu Sep 3 14:09:14 PDT 2020 x86_64 x86_64 x86_64 GNU/Linux
  
 [root@db1 ~]#  awk -F\' '$1=="menuentry " {print i++ " : " $2}' /etc/grub2.cfg
 0 : Oracle Linux Server (5.4.17-2011.6.2.el7uek.x86_64 with Unbreakable Enterprise Kernel) 7.9
 1 : Oracle Linux Server (3.10.0-1160.el7.x86_64 with Linux) 7.9
 2 : Oracle Linux Server (0-rescue-57724e4d2a064aaeabe79777a393dd73 with Linux) 7.9
[root@db1 ~]# grub2-set-default 1
[root@db1 ~]# grub2-mkconfig -o /boot/grub2/grub.cfg
sed: can't read /etc/system-release: No such file or directory
解决方法:
 [root@db1 ~]# cp /etc/redhat-release /etc/redhat-release.bak
 [root@db1 ~]# mv /etc/redhat-release /etc/oracle-release
解决后再次执行
[root@db1 ~]# grub2-mkconfig -o /boot/grub2/grub.cfg
 Generating grub configuration file ...
 Found linux image: /boot/vmlinuz-5.4.17-2102.201.3.el7uek.x86_64
 Found initrd image: /boot/initramfs-5.4.17-2102.201.3.el7uek.x86_64.img
 Found linux image: /boot/vmlinuz-3.10.0-1160.el7.x86_64
 Found initrd image: /boot/initramfs-3.10.0-1160.el7.x86_64.img
 Found linux image: /boot/vmlinuz-0-rescue-2f30d4e108e947abbe8c295cfc5d8716
 Found initrd image: /boot/initramfs-0-rescue-2f30d4e108e947abbe8c295cfc5d8716.img
done
 [root@db1 ~]# reboot
重启后查看
[root@db1 ~]# uname -a
 Linux db1 3.10.0-1160.el7.x86_64 #1 SMP Thu Oct 1 17:21:35 PDT 2020 x86_64 x86_64 x86_64 GNU/Linux
 [root@db1 ~]#










