Issue
Your DELL server is unable to boot from UEFI partition once you have converted Almalinux\RockyLinux to CloudLinux.
Environment
- AlmaLinux/RockyLinux
- CloudLinux
- Dell servers (only a few specific Dell servers)
Solution
In case your server is still UP after conversion and you didn't reboot it yet, do:
cp -rp /boot/efi/EFI/centos/* /boot/efi/EFI/almalinux/
In case the server is already not booting:
Boot AlmaLinux 8 or CentOS 8 LiveCD. In the boot menu, choose Troubleshooting:
Then "Rescue an Almalinux system" or "Rescue a CentOS system" if you are running CentOS live CD:
When requested, if the system needs to be mounted, type "1" and press "Enter"
Press "Enter" again on a prompt to shell:
Type "chroot /mnt/sysroot" end press "Enter":
Type "cp -rp /boot/efi/EFI/centos/* /boot/efi/EFI/almalinux/" press "Enter" and then you can reboot.
In addition to the solution described above, on the servers where the fix was manually applied you also need to do the following:
- if /boot/efi is located on the usual disk partition (like /dev/sda1):
device="$(df -T /boot/efi | sed -n 2p | awk '{ print $1}')" disk_name="$(echo "${device}" | sed -re 's/(p|)[0-9]$//g')" disk_num="$(echo "${device}" | tail -c 2|sed 's|[^0-9]||g')" efibootmgr -c -L "CloudLinux" -l "\EFI\centos\shimx64.efi" -d "${disk_name}" -p "${disk_num}"
device="$(df -T /boot/efi | sed -n 2p | awk '{ print $1}')" soft_dev1="$(cat /proc/mdstat | grep "${device:5} " | awk '{ print $5}' | head -c -4)" soft_dev2="$(cat /proc/mdstat | grep "${device:5} " | awk '{ print $6}' | head -c -4)" echo "$soft_dev1" echo "$soft_dev2" disk_name1="$(echo "${soft_dev1}" | sed -re 's/(p|)[0-9]$//g')" disk_name2="$(echo "${soft_dev2}" | sed -re 's/(p|)[0-9]$//g')" disk_num1="$(echo "${soft_dev1}" | tail -c 2|sed 's|[^0-9]||g')" disk_num2="$(echo "${soft_dev2}" | tail -c 2|sed 's|[^0-9]||g')"
efibootmgr -c -L "CloudLinux" -l "\EFI\centos\shimx64.efi" -d "${disk_name1}" -p "${disk_num1}" efibootmgr -c -L "CloudLinux" -l "\EFI\centos\shimx64.efi" -d "${disk_name2}" -p "${disk_num2}"
Cause
The conversion of Almalinux to Cloudlinux moving bootloader to /boot/efi/EFI/centos directory but on DELL's - new bootloader configuration is not detected on some DELL servers. The root cause is being investigated.
Comments
1 comment
Correct two last commands:
Please sign in to leave a comment.