#-- If the ISO files from the following URL are live bootable to a command line or desktop with NVMe support.
#-- Make sure that the one you download has the exact same kernel version as the failing installation.
#-- https://www.ubuntu.com/download/server/arm
#-- Mount the installation that is failing to boot at : /media/live-user-name or ubuntu here/.......... (or similar). This will become the new root file system (/).
#-- Hide the ugly path in a meaning variable name, for repetitive use.
failing_target="/media/live-user-name or ubuntu here/.........." .
#-- Move into the failing target.
cd "$failing_target"
mount -t sysfs /sys sys/
mount -t proc /proc proc/
mount -o bind /dev dev/
mount --rbind /run run/
cp /etc/resolv.conf etc/resolv.conf
#-- Descend into failing (s)hell. Swaps root file systems, from live to failing.
chroot "/$failing_target" /bin/bash
#-- Ask the developer of the distro for the kernel module names, and in which file to enable them. I'm not an Ubuntu user, sorry. Arch Linux here.
#-- Or look in /proc/modules and try to find them, then use module-assistant and lsmod. But then you still need to find out how to dynamically load them.
#-- Maybe this is of use, although i doubt it : http://manpages.ubuntu.com/manpages/bion...eebsd.html
#-- Backup/Rename your current initramfs (/boot/initrd.img-*)
#-- Update initramfs against the newest/latest kernel version.
update-initramfs -u
#-- If update-initramfs fails with a read-only file system message (shouldn't). Use mkinitramfs instead.
mkinitramfs -o /boot/initrd.img-$(uname -r) #-- For the currently running kernel.
#-- Leave the chrooted environment. Returning to the live root file system.
exit
This is from Arch Linux (except for the commands to build initrd). It might be (slightly) different on Ubuntu.
#-- Make sure that the one you download has the exact same kernel version as the failing installation.
#-- https://www.ubuntu.com/download/server/arm
#-- Mount the installation that is failing to boot at : /media/live-user-name or ubuntu here/.......... (or similar). This will become the new root file system (/).
#-- Hide the ugly path in a meaning variable name, for repetitive use.
failing_target="/media/live-user-name or ubuntu here/.........." .
#-- Move into the failing target.
cd "$failing_target"
mount -t sysfs /sys sys/
mount -t proc /proc proc/
mount -o bind /dev dev/
mount --rbind /run run/
cp /etc/resolv.conf etc/resolv.conf
#-- Descend into failing (s)hell. Swaps root file systems, from live to failing.
chroot "/$failing_target" /bin/bash
#-- Ask the developer of the distro for the kernel module names, and in which file to enable them. I'm not an Ubuntu user, sorry. Arch Linux here.
#-- Or look in /proc/modules and try to find them, then use module-assistant and lsmod. But then you still need to find out how to dynamically load them.
#-- Maybe this is of use, although i doubt it : http://manpages.ubuntu.com/manpages/bion...eebsd.html
#-- Backup/Rename your current initramfs (/boot/initrd.img-*)
#-- Update initramfs against the newest/latest kernel version.
update-initramfs -u
#-- If update-initramfs fails with a read-only file system message (shouldn't). Use mkinitramfs instead.
mkinitramfs -o /boot/initrd.img-$(uname -r) #-- For the currently running kernel.
#-- Leave the chrooted environment. Returning to the live root file system.
exit
This is from Arch Linux (except for the commands to build initrd). It might be (slightly) different on Ubuntu.