Browsing zfs snapshots

I have some hosts running lxd with zfs storage. There’s a background process which takes periodic snapshots (not using lxc snapshot, just zfs dataset snapshots)

If the dataset were mounted on the host, then as well as the data I’d be able to see the snapshots in the hidden .zfs/snapshot directory.

However, since lxd moved to snap, the dataset is no longer mounted on the host, but in some sort of snap namespace. Inside the container itself, /.zfs/snapshot/ does not exist.

Does anyone have any clues as to how I could inspect the zfs snapshots?

I thought I got it, thanks to a search on nsenter in the forum:

nsenter --mount=/run/snapd/ns/lxd.mnt bash
ls /var/snap/lxd/common/lxd/storage-pools/default/containers/XXXX/.zfs/snapshot

But no: the snapshots are all listed, but are all empty directories :frowning: