there was one “-” too much.
Try:
sudo snap refresh lxd --channel=latest/candidate
there was one “-” too much.
Try:
sudo snap refresh lxd --channel=latest/candidate
lxc config show
config:
backups.compression_algorithm: zstd
core.https_address: :8443
core.trust_password: true
images.auto_update_interval: “0”
images.compression_algorithm: zstd
images.default_architecture: x86_64
images.remote_cache_expiry: “0”
storage.images_volume: pl/images
lxc storage ls
±-----±-------±-------±------------±--------±--------+
| NAME | DRIVER | SOURCE | DESCRIPTION | USED BY | STATE |
±-----±-------±-------±------------±--------±--------+
| pl | zfs | zp2/pl | | 10 | CREATED |
±-----±-------±-------±------------±--------±--------+
lxc storage volume ls pl
±----------±-------±------------±-------------±--------+
| TYPE | NAME | DESCRIPTION | CONTENT-TYPE | USED BY |
±----------±-------±------------±-------------±--------+
| container | FC-HA | | filesystem | 1 |
±----------±-------±------------±-------------±--------+
| container | FC-Sql | | filesystem | 1 |
±----------±-------±------------±-------------±--------+
| custom | images | | filesystem | 1 |
sudo snap refresh lxd --channel=latest/candidate
sudo snap list
Name Version Rev Tracking Publisher Notes
core18 20211215 2284 latest/stable canonical✓ base
core20 20220304 1376 latest/stable canonical✓ base
distrobuilder 2.0 1125 latest/stable stgraber classic
lxd 4.24 22662 latest/candidate canonical✓ -
snapd 2.54.4 15177 latest/stable canonical✓ snapd
lxc launch images:alpine/edge alp1
Creating alp1
Starting alp1
all worked fine.
I just dont get where the images are stored.
By config key storage.images_volume: pl/images
images supposed to go into custom:
zp2/pl/custom 2.56M 95.4G 24K none
zp2/pl/custom/default_images 2.54M 95.4G 2.54M legacy
yet the image for above newly created container went to:
zp2/pl/images/366eb5ca6175b9d25f2190997e5826d3767ceac30d8c048fa73552d742d1af0f 8.29M 95.4G 8.29M legacy
Ah yes sorry about that, have corrected it.
OK so the 4.24 candidate snap channel should fix your issue (although do be sure to refresh back to the latest/stable
channel once LXD 4.24 is pushed to stable so you don’t get the next candidate unexpectedly in the future).
You both use a dedicated image custom volume storage.images_volume
so are both being affected by:
Which is fixed in 4.24.
When the compressed image files are downloaded they are normally stored in a location on your /
partition inside the snap. However if you set storage.images_volume
then these compressed files will be stored in the custom volume you specify. This can prevent the /
partition be filled up with downloaded images.
Then when you create an instance from one of those images, if the storage pool being used supports efficient snapshots, then first the compressed image file is unpacked into an “image volume” on the storage pool in question.
Then the instance being launched is created by taking a snapshot of that image volume, and subsequent instances created from that image are also created as snapshots from that image volume.
In this way multiple instances do not need to duplicate the base image file contents repeatedly.
snap list
Name Version Rev Tracking Publisher Notes
core18 20211215 2284 latest/stable canonical✓ base
core20 20220304 1376 latest/stable canonical✓ base
lxd 4.24 22662 latest/candidate canonical✓ -
snapd 2.54.4 15177 latest/stable canonical✓ snapd
lxc launch ubuntu:20.04 test -p default -p macvlan -s s860
Creating test
Starting test
lxc image ls
+-------+--------------+--------+---------------------------------------------+--------------+-----------+----------+------------------------------+
| ALIAS | FINGERPRINT | PUBLIC | DESCRIPTION | ARCHITECTURE | TYPE | SIZE | UPLOAD DATE |
+-------+--------------+--------+---------------------------------------------+--------------+-----------+----------+------------------------------+
| | 06460ff79260 | no | ubuntu 20.04 LTS amd64 (release) (20220308) | x86_64 | CONTAINER | 387.48MB | Mar 15, 2022 at 8:50am (UTC) |
+-------+--------------+--------+---------------------------------------------+--------------+-----------+----------+------------------------------+
lxc storage ls
+------+--------+----------------+-------------+---------+---------+
| NAME | DRIVER | SOURCE | DESCRIPTION | USED BY | STATE |
+------+--------+----------------+-------------+---------+---------+
| s860 | dir | /mnt/s860/lxd4 | | 16 | CREATED |
+------+--------+----------------+-------------+---------+---------+
lxc storage volume ls s860 (not a complete list)
+----------------------+--------------+-------------+--------------+---------+
| TYPE | NAME | DESCRIPTION | CONTENT-TYPE | USED BY |
+----------------------+--------------+-------------+--------------+---------+
| .... | ... | | filesystem | 1 |
+----------------------+--------------+-------------+--------------+---------+
| container | pw1 | | filesystem | 1 |
+----------------------+--------------+-------------+--------------+---------+
| container (snapshot) | pw1/20211028 | | filesystem | 1 |
+----------------------+--------------+-------------+--------------+---------+
| container | t2004 | | filesystem | 1 |
+----------------------+--------------+-------------+--------------+---------+
| container | test | | filesystem | 1 |
+----------------------+--------------+-------------+--------------+---------+
| custom | backup | | filesystem | 1 |
+----------------------+--------------+-------------+--------------+---------+
| custom | images | | filesystem | 1 |
+----------------------+--------------+-------------+--------------+---------+
lxc config show
config:
storage.backups_volume: s860/backup
storage.images_volume: s860/images
Is it working now?
If you run lxc image delete 06460ff79260
and then delete any instances you cannot start, this should clean up the problematic image volumes and allow you to re-download and unpack a fresh image now that you’re running LXD 4.24.
Yes; the error is gone
Excellent thanks
tracking: latest/edge
which is counter to what you said originally LXD 4.23
, because latest/edge
is unstable and further on than the 4.23 release.
Is there a reason you’re on edge? You’re likely being affected by (https://github.com/lxc/lxd/pull/9975) so a snap refresh lxd
might help, but you probably also need to do lxc image delete
on the affected cached images).
Not the list, Off topic - The best Image Compression website is https://pdfinsider.com/en