Error importing image from LXC (4.10.0) to new Incus cluster

I created an export of a container on a LXC (4.10.0) Ubuntu 20.04 system, and am trying to import it to Incus on Debian unstable. It fails with the error Error: Post "http://unix.socket/1.0/instances": EOF.

lwf@sulfur2:~$ incus import '/media/[...]/unifi.tar.gz' 
Importing instance: 100% (37.54MB/s)Error: Post "http://unix.socket/1.0/instances": EOF
lwf@sulfur2:~$ incus storage list
+---------+--------+-------------+---------+---------+
|  NAME   | DRIVER | DESCRIPTION | USED BY |  STATE  |
+---------+--------+-------------+---------+---------+
| default | btrfs  |             | 1       | CREATED |
+---------+--------+-------------+---------+---------+
lwf@sulfur2:~$ incus list
+------+-------+------+------+------+-----------+
| NAME | STATE | IPV4 | IPV6 | TYPE | SNAPSHOTS |
+------+-------+------+------+------+-----------+
lwf@sulfur2:~$ incus version
Client version: 6.0.3
Server version: 6.0.3

This has been fixed already in Incus 6.10 (released yesterday) and that bugfix will make its way into Incus 6.0.4 (planned by end of March) which is what we’re expecting the release version of Incus to be for trixie.

You basically need this fix: Fix importing from older backups by stgraber · Pull Request #1683 · lxc/incus · GitHub

1 Like

Thanks for the pointer @stgraber

After upgrading, import still fails with:

$ incus import ~/Documents/unifi.tar.gz 
Error: Failed importing backup: Failed checking snapshots: Snapshot count in backup config (4) and storage device (0) are different: Backup snapshots mismatch

Backup was created with --instance-only flag, should I instead back up all snapshots or delete all but the latest?

Worth a try. Sounds like the backup generation is buggy on the 4.0 side…