Cannot install LXD on ipv6-only system

I tried to install LXD on an ipv6-only system (hetzner vps), in order to improve my ipv6 experience, and I couldn’t:

sudo snap install lxd
error: cannot install "lxd": persistent network error: Post
"https://api.snapcraft.io/v2/snaps/refresh": dial tcp 185.125.188.55:443:
connect: network is unreachable

Running “dig -t AAAA api.snapcraft.io” shows that api.snapcraft.io does not have an ipv6 address.

It turns out that this is a snap bug:
See Snap store APIs (api.snapcraft.io) are not reachable via IPv6

Therefore, it is also an LXD bug.

I’m happy to report that Incus can be installed on an ipv6-only system and it works.

1 Like

Yeah, the vast majority of my internal servers and containers are IPv6-only with only the public facing bits (haproxy and the like) also getting IPv4 for client connections.

We’re also careful that things like image mirrors are either dual-stack themselves or that our dispatcher checks what protocol the client used to reach us and then not redirect to a server which doesn’t support that protocol. This then lets us run IPv6-only or IPv4-only image mirrors just fine.