Method for moving to new server

I have several factors that seem to be making things difficult when trying to move containers to a new server.

Existing server:
LXD is installed as an apt package.

$ lxd version

New server:
LXD is installed as a snap package.

$ lxd version

I thought I could just configure the existing server to include the new server as a remote host with:

lxc remote add newserver [ip_of_newserver]

but I got this:

Error: Get https://[ip_of_newserver]:8443: remote error: tls: protocol version not supported

I understand that this is related to the versions being so different. I read that I can just set LXD_INSECURE_TLS=true in the environment of the LXD 5.0 system, which I will do (in the hope that I can copy containers from existing to new). But ultimately I would like to upgrade the existing server to 5.0 using snap so I can easily copy containers between the two and not set that value (which at least seems insecure).

Is there guidance somewhere on doing such an upgrade? Is this a reasonable approach that will result in two systems that can easily exchange containers?


1 Like

If possible, easiest would be to upgrade the existing server first.

You should be able to do:

  • snap install lxd --channel=4.0
  • lxd.migrate

This will get you onto LXD 4.0. You could then also do snap refresh lxd --channel=5.0 if you want to move to 5.0, but I suspect 4.0 will be good enough to migrate the instances off.


Wonderful! Thank you.

Should I assume lxd.migrate process will bring down the server?

Yeah, it will shutdown all instances during the migration, so best plan for a maintenance window!

Which is different from normal LXD version upgrade which does not impact running instances.

Understood. Thank you.