From 246a685a644a383e10e4f1a2d8155d913314a98c Mon Sep 17 00:00:00 2001 From: dz00te Date: Thu, 6 May 2021 13:03:07 +0200 Subject: [PATCH 1/2] add multi-arch fix --- centos2rocky.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/centos2rocky.sh b/centos2rocky.sh index 396512e..7ba0607 100755 --- a/centos2rocky.sh +++ b/centos2rocky.sh @@ -33,7 +33,8 @@ export LANG=en_US.UTF-8 SUPPORTED_RELEASE="8.3" SUPPORTED_MAJOR="8" -current_url="https://dl.rockylinux.org/pub/rocky/${SUPPORTED_RELEASE}/BaseOS/x86_64/os/Packages" +ARCH=$(arch) +current_url="https://dl.rockylinux.org/pub/rocky/${SUPPORTED_RELEASE}/BaseOS/${ARCH}/os/Packages" # These are packages that can be swapped safely over and will have more added over time. packages_to_swap=( centos-backgrounds \ From 2eba3ded44deda10b63b8fc134c27701f7111f38 Mon Sep 17 00:00:00 2001 From: dz00te Date: Thu, 6 May 2021 19:30:49 +0200 Subject: [PATCH 2/2] add upgrade grub on efi --- centos2rocky.sh | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/centos2rocky.sh b/centos2rocky.sh index 7ba0607..17be961 100755 --- a/centos2rocky.sh +++ b/centos2rocky.sh @@ -137,6 +137,14 @@ sig_swaps() { exit_message "Not Available" } +grub_swap() { + if [ -d /sys/firmware/efi ]; then + grub2-mkconfig -o /boot/efi/EFI/rocky/grub.cfg + else + grub2-mkconfig -o /boot/grub2/grub.cfg + fi +} + module_check() { echo -e "$blue""Finding our modules that are enabled""$nocolor" for module in "${enabled_modules[@]}"; do @@ -252,6 +260,9 @@ module_check # Actually do the swap and distro-sync package_swaps +# Reconfigure grub +grub_swap + # Fix up modules module_fix