Delete snapshot failed

while copying from remote instance an error occurred in the create process and a snapshot is now in the database which doesn’t exist on the storage pool.
now i get:
lxc delete apphost/snap0 --force 1 :frowning: 03/11/20 - 8:29 PM
Error: lstat /var/snap/lxd/common/lxd/storage-pools/default/containers-snapshots/apphost/snap0/: no such file or directory

How to get rid of the snapshot and the container in this case?

Thanks in advance guys

What storage backend is that on?

Hi Stephane!

It’s BTRFS, thanks.

nsenter --mount=/run/snapd/ns/lxd.mnt mkdir -p /var/snap/lxd/common/lxd/storage-pools/default/containers-snapshots/apphost
nsenter --mount=/run/snapd/ns/lxd.mmt /snap/lxd/current/bin/btrfs subvol create var/snap/lxd/common/lxd/storage-pools/default/containers-snapshots/apphost/snap0

That should create the thing it was trying to delete.

Thanks Stephane, solved the problem.