1

I have Lxd installed on an Arch system (from packages, not snapd), yesterday I rebooted the system after an upgrade and the name resolution of the fake domain .lxd stopped working; dns is provided on 10.0.10.1 from dnsmasq, launched by lxc-net service. dnsmasq is used also to provide an internal domain to other hosts on the network, and this is working well. with netstat -lnp I can see both instances of dnsmasq binded on the correct addresses, but:

  • when I ping one container (e.g. ping proxy.lxd) from within another one the ip of the main network card of the host is resolved (192.168.1.63), and ping works.
  • when pinging direclty the ip address of the other container it works.
  • the same command on the host gives ping: proxy.lxd: Name or service unknown.

System's dnsmasq (not the one started by lxc-net) is configured with: server=/lxd/10.0.10.1 and it worked fine until yesterday.

The upgrade didn't involve dnsmasq or the lxc-net script, but there was un upgrade of lxd from 4.8-1 to 4.9-1

It seems related to dnsmasq somehow, but could not find a way to understand and solve it.

network works fine in both containers and host, just dns went to... /dev/null Is this happened to someone? How can I re-solve it?

Spuria
  • 11
  • 3

1 Answers1

0

Well, it was somehow my fault. still don't actually know why it happened, but after some digging I can't honestly say how was it working before. That said, the "solution" was to configure the system :)

I disabled the lxc-net script previously used to set up the network bridge and dnsmasq, then:

  • lxc network create bridgename to create the bridge an manage it in lxd;
  • lxc network edit bridgename to configure it;
  • added the bridge to default profile (lxc profile edit default);
  • configured /etc/dnsmasq.conf to listen on 127.0.0.1, the nic address and the bridge address, set up dhcp only for bridge address, addedd local=/lxd/ in order to resolve container.lxd.

then it worked.

Spuria
  • 11
  • 3