Name resolution problem since 0.97.2

I would if I knew how to do that kind of coding. Alas, I’m not knowledgeable at all in that.

And honestly I’m not even sure what “that” even is… :laughing:

I assume it’s python?

Hi,
for any reasons my issues still exists. I’m on Supervisor Visor 180. I already downgraded to 173 and everything works again for a few minutes, until the Autoupdate to 180.

the CLI shows me this.

24

I’m confused. Should the first DNS not 9.9.9.9 because of Quad9?!?!

Did the update went correct?
Please help

FYI: In case anyone else runs into it, Home assistant started to fail to connect to MariaDB on bootup, since the host values were set to homeassistant for me and for some reason Maria was receiving the hostname as core-samba.local.hass.io, so I got a bunch of errors similar to:

2019-08-18 16:41:11 ERROR (Recorder) [homeassistant.components.recorder] Error during connection setup: (MySQLdb._exceptions.OperationalError) (1130, "Host 'core-samba.local.hass.io' is not allowed to connect to this MariaDB server")
(Background on this error at: http://sqlalche.me/e/e3q8) (retrying in 3 seconds)

I switched the host to % to resolve it for now since I would assume the hostname will change with the fixes/changes that are happening related to DNS (don’t know why it’s showing up as the samba container and not homeassistant).

//TB

Version 181 fixed the IP connection issue. Thanks a lot.
MariaDB still not working with old settings. I will try @docBliny changes

With 181 my installation off hass.io on raspi does work again including all my addons:
Log Viewer
Node-RED
SSH & Web Terminal
TasmoAdmin
zigbee2mqtt

Thanks a lot!

But no logs or anything else useful. This is not a place to simply say it doesn’t work.

I am on .97.2 181 with this same issue where hassio doesn’t resolve any local DNS addresses. I tried the "hassio dns options --servers dns://<local_dns_ip> and it set but didn’t make a difference

I do see this in the System Log:

19-08-19 01:17:06 WARNING (MainThread) [hassio.dns] Can't write local resolv: [Errno 13] Permission denied: '/etc/resolv.conf'

Any other suggestions?

It doesn’t seem to be able to ping short names now, you have to ping FQDN after adding your local dns server and restarting the dns service. More info here https://github.com/home-assistant/hassio/issues/1231

–nevermind- reverted back to plain HA

I was sometimes getting this error message Permission denied: '/etc/resolv.conf' but then my hassio has never managed to resolve ‘.local’ addresses on my network.

Dude… this had me trippin for a few days! I have my home router (pfSense) block all outbound DNS request. My router runs a resover and forces all queries over TLS to 1.1.1.1 or Quad9. When my hassio supervisor auto-updated hass lost all ability to resolve hosts!

I realize I am probably an edge case, but is there a way to notify users of a “breaking change” like this before it auto-applies?

I have a similar problem to this but the resolution works fine. What I’m curious about is the sheer amount of DNS queries being made by my HA instance running through Hassio on an RPi. It keeps making queries for domains with in-addr.arpa in the name. For example:
42.1.168.192.in-addr.arpa
The queries are relentless and I’m not sure where to start to try and debug this.

Edit: Apparently this isn’t an issue per this GitHub issue, but it’s very odd that the spike started all of a sudden considering it wasn’t happening before.

They are reverse dns lookups.

There is a feature request for blocking supervisor auto-updates. If you dont like the auto-update machanism vote against it here: Feature request: block supervisor auto-updates

1 Like

For a general user with external DNS, I can understand that there’s going to be a lot of “NXDOMAIN” responses, but my system’s setup with an internal DNS, DHCP, etc and knows that “.home” doesn’t exist.

From an external DNS point of view, that’s true (& I agree), but internally, with my own DNS server and everything using a DNS Suffix searchlist of “.home” means that I can use “devicename” and it still resolves to the correct IP.

Using avahi and “.local” is great for those that don’t have any networking experience and / or want to just have everything automatically find everything else and that’s great for a system like this, but that’s not how I run my network (and this is a debate for another place).

So, from my point of view, you’re implementing avahi… cool, that’s the project’s choice… now, I just want to disable / bypass / use my own DNS for my system…

So, I’m just looking for options in the project here… the system can arrive pre-configured but I’d like to switch to “advanced mode” and change the defaults :slight_smile:

If that’s in an new “networking.yaml” (for example), or a webGUI page, that’s cool… command line’s less desirable, but if that gets me setup, then that’s what I’ll do.

1 Like

How to reset the dns configuration?

I’m on supervisor 184 and I think now it should be working. I changed my hostname to fqdn (even though I concur that it never was and should not be necessary), but it still not able to resolve the hassio official MariaDB addon.

Here’s the output of the command
image

It seems to resolve correctly, but then I guess the SERVFAIL somehow messes things because the recorder cannot connect to the database.

Thanks

What a terrible design. Why is it so incredibly difficult to set something as simple as a DNS resolver? I just installed Hass.io via Debian/Docker and I have wasted so much time trying to figure out how to set my own resolver, and even after reading this thread I am completely lost.

Something so rudimentary shouldn’t be so ridiculously difficult. Please fix this.

2 Likes

Running hass.io in Docker on Ubuntu; my hassio_dns docker container can resolve short names on my network with no issue (I removed all other dns besides 192.168.1.1 from /usr/share/hassio/dns/corefile); however my homeassistant container can not resolve any local addresses not in the hassio_dns container’s hosts file, internet addresses are okay.

The only way I can seem to get this working properly is to go into nuke search from homeassistant container’s /etc/resolv.conf…

docker exec -it homeassistant bash -c 'cp /etc/resolv.conf /tmp/resolv.conf.old; grep -v search /tmp/resolv.conf.old > /etc/resolv.conf'

However I can’t figure out how to persist that change across restarts.

@dogcow

Did you both read the link here Name resolution problem since 0.97.2

I don’t know about dogcow, but I read it… doesn’t help me at all… I don’t have a ‘hassio’ command, and even if I did it still doesn’t address that the dns search base doesn’t allow for resolving local names not residing in the .hass.io name space, for which none of the devices on my lan live in outside of the hassio_* docker containers are.