DNS Error: Unable to Resolve Host

Home Assistant 2023.1.7
Supervisor 2022.12.1
Operating System 9.4
Frontend 20230110.0 - latest
Hardware: RaspberryPi 3 connected via ethernet

I was attempting to install HACS and I kept getting a resolve error. Upon further inspection, it goes beyond HACS.

I attempt to ping google.com and I get: ping: bad address ‘google.com
I did a dig google and I get communications error to 172.30.32.3#53: timed out

I have set the DNS manually to 8.8.8.8,1.1.1.1 and I’ve repeatedly reset the hardware and reset DNS specifically.

I eventually did ha dns downgrade and everything started working - but this only seems to last for a few minutes. If I go back in 5 minutes or so and do a ping I get the same errors.

Any help would be appreciated!

what does “ha resolution info” say?

ha resolution info:

checks:
- enabled: true
  slug: network_interface_ipv4
- enabled: true
  slug: addon_pwned
- enabled: true
  slug: free_space
- enabled: true
  slug: backups
- enabled: true
  slug: dns_server_ipv6
- enabled: true
  slug: supervisor_trust
- enabled: true
  slug: dns_server
- enabled: true
  slug: core_security
issues:
- context: system
  reference: null
  type: no_current_backup
  uuid: bdf126dac6744479bf9778be22d45206
suggestions:
- auto: false
  context: system
  reference: null
  type: create_full_backup
  uuid: 33588c0861274f688936731018737e80
unhealthy: []
unsupported: []

What installation type do you use for HA?
Supervised or HAOS?

I use HAOS for my installation.

Ok, then the issue is most likely on your router, which report wrong settings in its DHCP info.

Home Assistant was working prior to this popping up randomly. I made no changes to my router, and the router is in the default state.

Additionally, HA works when I manually downgrade the DNS and then stops working when some unknown service breaks it later. If it was something with my router, wouldn’t the problem always be there?

Do you have other routers on the network or maybe an extra access point?

I have a second router that I use as a bridge to provide wifi out to my garage, but it has been there the entire time and the HA instance is conencted via ethernet.

That may then be acting as a dchp server too

Ok. Any advice on how to determine or correct that? I’m also not certain why this would have randomly changed.

Turn off while debugging this issue to see if it improves.

The devices get information about what IP, subnet default gateway, DNS servers and so on they should use.
A device might get the information from the correct router, but then the other router later discovers the device and sends a new set of information which is buggy.

Tried that, no change. I’m 99% sure it is not related to the router.

just a hunch, is IP6 enabled??
try turning it off in your router😉

Just tried. No change. :frowning:

No, I am not.
I am pretty sure it is related to your network and not really HA, unless you have installed a DHCP or DNS service addon on the HA.
The extra router is just a common occurring issue where configuration of the services are often done wrong, like connecting both the two routers on the network on one of their LAN ports and not making sure that DHCP and DNS is surely disabled on one of the routers.

DHCP is disabled on the second router. Also, it was working until recently. I made no changes to the network - it is as it has been and it has been working. Also, all other devices are working and able to ping and access the internet without a problem - including another pie running Raspbian.

What addons are you running on your HAOS?

Currently only running the SSH Terminal add on since I reinstalled the OS in a rage and haven’t configured anything. Pretty bare bones.

Try this before we go on.