Working of DNS in container

Hello,

I’m trying to resolve local names in the hassio container.

I tried to configure the hassio with the local dns and rebooted the dns server (and later the whole machine). So now I have:

core-ssh:~# hassio dns info
host: 172.30.32.3
latest_version: "1"
locals: []
servers:
- dns://192.168.178.1
version: "1"

When I try to resolve with host, I don’t get any answer:

core-ssh:~# host c02meter
Host c02meter not found: 3(NXDOMAIN)
core-ssh:~# host co2meter.fritz.box
Host co2meter.fritz.box not found: 3(NXDOMAIN)

(very sometimes I do:)

core-ssh:~# host co2meter.fritz.box
Host co2meter.fritz.box not found: 3(NXDOMAIN)
core-ssh:~# host co2meter.fritz.box
Host co2meter.fritz.box not found: 3(NXDOMAIN)
core-ssh:~# host co2meter.fritz.box
Host co2meter.fritz.box not found: 3(NXDOMAIN)
core-ssh:~# host co2meter.fritz.box
co2meter.fritz.box has address 192.168.178.24
Host co2meter.fritz.box not found: 3(NXDOMAIN)
core-ssh:~# host co2meter.fritz.box
Host co2meter.fritz.box not found: 3(NXDOMAIN)

Using hosts with the dns host behind it, doesn’t give any issues.

core-ssh:~# host co2meter.fritz.box 192.168.178.1
Using domain server:
Name: 192.168.178.1
Address: 192.168.178.1#53
Aliases:

co2meter.fritz.box has address 192.168.178.24
core-ssh:~# host co2meter 192.168.178.1
Using domain server:
Name: 192.168.178.1
Address: 192.168.178.1#53
Aliases:

co2meter has address 192.168.178.24

What am I missing to get this working?

Using:

  • Nuc
  • Ubuntu 18.04.3 LTS
  • homeassistant: 0.102.1
  • supervisor: “192”

hello, have you solved it??

Changed some network configuration and hassio was after that not even noticing updates due to dns failures. Yesterday reinstalled everything. Now looks ok, but haven’t checked full names in the configuration yet.

I’m also having this problem. HA is using 1.1.1.1 to resolve names despite my making the appropriate changes.

Have you tried changing the DNS to your home DNS server?

~ $ ha dns --help

The dns command allows you to manage the internal Home Assistant DNS server by
exposing commands to view, monitor, configure and control it.

Usage:
ha dns [command]

Examples:

ha dns logs
ha dns info
ha dns update

Available Commands:
info Shows information about the internal Home Assistant DNS server
logs View the log output of the Home Assistant DNS server
options Allow to set options for the internal Home Assistant DNS server
reset Resets the internal Home Assistant DNS server configuration
restart Restarts the internal Home Assistant DNS server
stats Provides system usage stats of the Home Assistant DNS server
update Updates the internal Home Assistant DNS server

bash-5.0# ha dns info
host: 172.30.32.3
latest_version: "1"
locals:
- dns://192.168.25.81
servers:
- dns://192.168.25.81
version: "1"

Unfortunately, yes.

Is the 192.168.25.81 is your router gateway? Does this DNS settings work?

I don’t recall exactly what fixed it, maybe an update, maybe settings were changed, but it’s been fixed for many months now. Thanks