I am planning to switch both the OS and the container solution, ideally the same time.
At the moment I am using Ubuntu Jammy with LXD from snapstore and I plan to switch to Debian Bookworm and Incus.
What would be the best way to proceed? Can I use LXC to export my containers and simply import them later to Incus after installing Debian? Or do I have to use the lxd-to-incus migration script while still on Jammy and export them?
Save /var/lib/incus and any storage that you’re using
Reinstall
Restore /var/lib/incus and your storage
You could also go with the export route but in that case, make sure to also note down things like networks, profiles, projects, … as export only gets you the container or volume you’re exporting.
After installing Incus 6.0-lts from zabbly repo I stopped all its services, wiped /var/lib/incus and replaced with the backup. Started the services again. And everything just worked. Awesome.
Once thing I noticed, after switching from Jammy to Bookworm as host OS, is that I have to apply setcap cap_net_raw+p to binaries like /bin/ping in order to work as regular user inside containers. I assume this is some restriction applying to Debian?
Does that only affect existing containers or new containers too?
fscaps in namespaces are a bit weird, so if only existing containers, a remapping operation probably somehow missed or miscalculated the new attribute. If on new containers, then we may have some weird issue with VFS idmap and the namespace-aware fscaps format.