hakuna-m/wubiuefi

Release upgrade from 20.04 to 22.04 possible without issues?

dieter-erich opened this issue · 7 comments

Hi,
I have a 20.04 Ubuntu Mate installation under Win7 that works just fine. Nevertheless, I am considering upgrading to 22.04. Is this possible without issue by just using 'release upgrade'? The laptop is old (sic Win7) and does not have Bitlocker!
Thanks, best, Dieter

Honestly, I have never tried an upgrade from 20.04 to 22.04. But we changed some patches for 22.04 because package lupin-support has been dropped since 22.04

So probably it is a good idea to install the new patches and remove package lupin-support as workaround for possible issues.

We need 3 changed patches:

  1. grub-install -> /usr/local/sbin
    which does not install GRUB in MBR or EFI partition
  2. grub-mkimage-lupin -> /usr/local/sbin
    which creates wubildr on Windows partition
  3. 10_lupin -> /etc/grub.d
    which creates the Grub menu entries for Wubi

As you see the 3 patches avoid to install GRUB in MBR or EFI partition and an empty GRUB menu. Here is a possible way to change the patches in 20.04 to that one which are used in 22.04:

# create temporary directory and use it
cd $(mktemp -d)
# download patches
wget https://raw.githubusercontent.com/hakuna-m/wubiuefi/master/data/custom-installation/patch/grub-install
wget https://raw.githubusercontent.com/hakuna-m/wubiuefi/master/data/custom-installation/patch/grub-mkimage-lupin
wget https://raw.githubusercontent.com/hakuna-m/wubiuefi/master/data/custom-installation/patch/10_lupin
# make it executable
sudo chmod +x grub-install
sudo chmod +x grub-mkimage-lupin
sudo chmod +x 10_lupin
# change owner
sudo chown root:root grub-install
sudo chown root:root grub-mkimage-lupin
sudo chown root:root 10_lupin
# copy patches to /usr/local/sbin
sudo mv grub-install /usr/local/sbin/grub-install
sudo mv grub-mkimage-lupin /usr/local/sbin/grub-mkimage-lupin
# remove unused patch
sudo rm /usr/local/sbin/grub-install-efi
# remove unused package
sudo apt-get remove lupin-support
# add grub entries for Wubi
sudo mv 10_lupin /etc/grub.d/10_lupin
sudo update-grub

As you know it is also a good idea to make a backup of /ubuntu/disks/root.disk before fixing and upgrading.