I have LXD running on a laptop with limited SSD storage (Ubuntu 20.04LTS, LXD 4.16, latest/stable snap). I have configured an additional storage pool on a removable USB3 hard drive so I can launch containers on this removable storage.
I have successfully created a storage pool on the removable device
lxc storage create lxd-btrfs-stick btrfs source=/dev/sdb1
and then launched a new container using that storage
lxc launch images:ubuntu/21.04 -s lxd-btrfs-stick
Container runs as expected.
If, however I remove the storage and start the host laptop without, lxd does not appear to start and any attempts to communicate using lxc
commands return
Error: Get “http://unix.socket/1.0”: EOF
If I replace the storage device and run snap restart lxd
it will then respond correctly, the container on the removable device will start and is accessible.
Is there a way I can temporarily disconnect this storage (and associated containers) from the pool so lxc will run without it?
Thanks for any advice.