I did a fresh install of Ubuntu Server 18.04. It came preinstalled with LXC/LXD version 3.0.3. Using apt update / apt upgrade did not make this any newer.
I then installed followed the instructions here and installed the snap version. This is 4.0.0. I then did lxd.migrate and everything works perfectly all the containers are running nicely.
However, I understand that the latest version is 4.0.3. Using apt update / apt upgrade makes no difference. I assume this is because it is a snap package. So I tried snap refresh. This also does not update LXC/LXD.
Is snap refresh the way to update snap packages? What am I doing wrong?
The Deb version of LXD is at version 3.0.3 and it is not expected to get upgraded to 4.0. You did the proper thing to switch to the snap version, then lxd.migrate to complete the migration.
It is possible to have, letās say a developer from Debian, to package LXD 4.0 as a deb package. And then decide whether to use that one. However, the snap version is a safe choice. There is a bit of learning curve, for example the snap version is not necessarily only LXD 4.0.
Run the following,
snap info lxd
It will show you the different channels, which correspond to different versions of LXD. You can switch forward from one version to a newer version. You may switch back two versions that are not too far apart.
By default you are tracking the latest/stable version. This one currently is at 4.0.0 (please verify).
As months go by, there will be 4.1, 4.2 and newer versions. By default, you will be upgraded automatically to the latesr version. If this is too fast for you, you can switch to the 4.0 channel, which does not receive any new features. Hence, it is conservative in favour of stability.
These are for LXC and LXCFS, which have independent minor-number versioning.
As far as I know, there is no minor number for LXD yet over 4.0.0. See https://github.com/lxc/lxd/releases
finally, workingā¦ uuntu18 with lxd 4.0.3
how to, working, perhaps not perfectā¦
after fresh install, apt update/upgrade
check if lxd is installed by defaut by deb package, (3.0.3)
apt list --installed | grep ālxd/ā
if present, stop lxd, all lxd and uninstall:
systemctl stop lxd
systemctl stop lxd.service
systemctl stop lxd.socket
apt purge lxd
apt autoremove
hash -r // force forget programm location
reboot
after reboot, new console:
snap info lxd // to get correct version channel
snap install lxd --channel=4.0/stable
snap list // to confirm correct lxd version useable from snap
hash -r
lxd version // now, it show 4.0.3 !
and you can continue with ālxd initā
question remainā¦
WHY they added snap tool and force lxd 3.0.3 deb package on install. ??
ubuntu users are as irresponsible as windows users ?? seen from canonical??