Lxc copy to remote of different (higher) version

It is possible to copy to an LXD remote of a high version?

Many thanks!

Yes that should be fine.

Thanks Thomas,

It appears I get “Error: Get https://1xxx.xxx.xxx.xxx:8443: remote error: tls: protocol version not supported”

Going from 3.6 → 5.1

Any ideas?

Many thanks,

Simon

See

Thanks again Thomas!

That has cleared the TLS issue, however it now hangs on the copy command.

local:
[root@shl1 ~]# lxc copy git-http lxd3:sftp

remote:

[root@shl2 ~]# lxc list
+------+---------+------+------+-----------+-----------+
| NAME |  STATE  | IPV4 | IPV6 |   TYPE    | SNAPSHOTS |
+------+---------+------+------+-----------+-----------+
| sftp | STOPPED |      |      | CONTAINER | 0         |
+------+---------+------+------+-----------+-----------+

There doesn’t appear to be any network activity.

Could you advise on diagnosing further?

Kind regards,

Simon

Try doing lxc export <instance> <file name>.tar.gz and then transfer the file manually to target and run lxc import <file name>.tar.gz on the target host.

Hmm, I’m getting:

[root@shl1 lxd]# lxc export git-http git-http.tgz -vvv
Error: Create backup: Backup storage: Could not create snapshot LV named snapshot--05236fd3--6b5f--4499--b074--7ae20cfb9d88

The reason I’m trying to backup containers is because I’m in the below situation. My sense is the above error might be related?..

Do you this I should reboot the host to recover state?

Many thanks,

Simon

Yes try a reboot

The above error persists after a reboot :man_facepalming:

Thanks for your helps so far - any advice on diagnosing further?

Kind regards,

Simon

Is the container running when you run lxc export?

Yes it was.

Try stopping it and doing export as that might skip the snapshot.

Alas, it appears to want to snapshot when STOPPED too…

Can you create a new storage pool of dir type and then copy the instance to it locally, then try exporting it from there.

1 Like
[root@shl1 lxd-export]~ lxc export git-http-bak git-http-bak.tgz
Backup exported successfully!           

Fab, thanks so much!!

1 Like

Nearly there! I can export the smaller ones, but even when exporting to a different partition lxd wants to consume space on the root partition which is nearly full. Is there some way to only use the target partition?

Many thanks,

Simon

Just found this!

See Lxc export behavior - #2 by tomp

Thanks Thomas,

I’m getting

[root@shl1 sw206]# lxc config set storage.backups_volume pool2/storage
Error: cannot set 'storage.backups_volume' to 'pool2/storage': unknown key

I’m on LXD 3.6 - was this config on a different key back then?

Many thanks,

Simon

Ah you cannot upgrade from 3.x to 5.x (only from 4.x), as 3.x is very old.

You could try upgrading the 3.x host to 4.x and then exporting and reimporting.