Let’s try to upgrade to Ubuntu Server 20.04 after a backup
I want to play around and learn ROS2, however the WSL environment on windows doesn’t seem fit. Also I am not keen on installing the Windows Version of ROS2 yet, as my work environment for ROS will stay Linux / Ubuntu anyway. So let’s upgrade my Homeserver to 20.04 instead to install ROS2 there.
Whatever, take me to the TR:DL already
Backing up the original rootfs
Since I installed the original filesystem in a seperate sub volume, this task is really easy. Just make a snapshot and for good measure, also send it to a second external btrfs drive.
❯ cd /mnt/btrfs ❯ ls @rootfs ❯ mount /dev/sdd /mnt/temp ❯ btrfs sub snap -r @rootfs @rootfs_ro_18_04 Create a readonly snapshot of '@rootfs' in './@rootfs_ro_18_04' ❯ btrfs send @rootfs_ro_18_04 | btrfs rec /mnt/temp At subvol @rootfs_ro_18_04 At subvol @rootfs_ro_18_04
Important to note is, this didn’t backup the btrfs subvolumes created by lxd, but They are not overly important to me on this device right now. I have backups of those containers in other places already. I am just hoping the upgrade will finish smoothly anyway.
Upgrade the OS
Getting right to it.
# make sure the system is up to date apt update && apt dist-upgrade -y # make sure upgrade manage is installed apt install update-manager-core # confirm that lts release upgrade is selected cat /etc/update-manager/release-upgrades
During the upgrade, the ssh session might disconnect. The upgrade manage will open a second ssh session on port 1022. So, just in case make sure the firewall allows that port, too.
Start the upgrade process
If this appears
Checking for a new Ubuntu release
There is no development version of an LTS available.
To upgrade to the latest non-LTS develoment release
set Prompt=normal in /etc/update-manager/release-upgrades.
the upgrade needs to be forced to check for “development” versions, too. Even after release it seems it’s marked as that.
Now just follow the on screen instructions, should be straight forward.
- I had a binded mount pointing from my storage hdd into the rootfs of an lxc container. This mount didn’t work anymore, because the rootfs location changed from
- Inside an lxc container, nordvpn was not working anymore. Removed it and reset the ip tables rules. I tried reinstalling, but than it couldn’t connect to their servers. I will try using it on a new 20.04 container some other time.
Maybe there won’t be a TLDR for this post.