How to throttle Supervisor's version check?

Oh man, things just get better and better and better.
With this most recent Supervisor update, I am now seeing tens of queries periodically for both . and checkonline.home-assistant.io
The best part is that I’ve not done any of the blocking that’s been talked about in this thread. The Supervisor just did this on its own! How wonderful~

What exactly has changed for you? I cannot see any remarkable difference since that Supervisor update.

What I mean is, I am seeing a set set of spammy requests.
Previously, I was only seeing the bursts of DNS requests for the updater/versioncheck/online checker domain. But with this update to the supervisor, my Pi-Hole and upstream DNS servers are being flooded with requests to resolve the domain . - which is wreaking havoc on how my resolvers are acting overall.

But long short, I am now seeing constant bursts of queries for both . and checkonline

I have never seen a bunch of requests for ., not sure what to make of that. Nothing was changed related to the online check for the latest supervisor (or for a while to my knowledge).

However due to this thread I did look into the swarms of checkonline queries. I was confused by this because supervisor actually only does a checkonline call every 10 minutes (or every 30 seconds if it believes your offline). When it does the check it does two things

  1. ask network manager to do a connectivity check to check the host (equivalent to running nmcli networking connectivity check in the host shell)
  2. make one HEAD request to checkonline.home-assistant.io to ensure supervisor’s DNS is good

Yet I too was seeing like 50 DNS requests at the same second every 10 minutes to checkonline.home-assistant.io.

Turns out it is network manager. When I ran nmcli networking connectivity check directly I got the same thing. It seems like it checks every network interface individually, including all the veths made for docker containers. Each one gets an A and an AAAA query :fearful:

I don’t really know why it does this, it’s automated check doesn’t work like this. I did some investigation with @agners and we think it’s a bug fixed by this commit in an upcoming version of NM.

I changed supervisor to reduce this by not asking NM to run a check and instead just asking it for the latest result of its own automated check. Along with a few other improvements that should massively reduce this in the next version of supervisor

EDIT: Ok actually probably the version after the next one. Next one should be 2022.08.6 which was cut before the PR. The one after that will have it.

3 Likes

So after the after after after update it should be good, might be the next year eventually, but still OK. IDK how this bug was never identified in the first place, but thanks for fixing it @CentralCommand!

1 Like

Running Home Assistant 2022.9.1 and it seems to have reduced by half- down from somewaht over 2.700 to approx 1.400 per day

That makes sense. There’s two parts to this fix:

1 - Supervisor should stop doing so many connectivity checks

This is done as of 2022.09.1. Supervisor now makes a maximum of one single HEAD call to checkonline.home-assistant.io every 10 minutes as long as the last one succeeded. Note if you block checkonline.home-assistant.io or your network really is down then you will see more then this. But as long as things are going smoothly, this is the max.

Besides that it no longer forces Network Manager to run any checks automatically. It will force Network Manager to run a check if someone calls ha network reload or updates Network settings via supervisor but never on a schedule, manual intervention is required. Instead it lets Network Manager do its connectivity checks and simply checks the status of the last one. And I confirmed in testing that checking the status of Network Manager’s last connectivity check does not cause any HTTP calls.

2 - Update Network Manager

There’s still something wonky with how NM is doing connectivity checks in this version. It happens less with the automated checks but when I’m watching Network Manager’s debug logs its still happening.

If you are on HAOS then v9.0 includes an update to Network Manager that fixes this, I’m seeing a massive reduction there. If you are on a supervised install then you’ll have to do a similar update to Network Manager yourself if it is bothering you. There’s not really anything supervisor can do here, you have to update the host packages yourself.

1 Like

The resolver log of my firewall shows requests for checkonline.home-assistant.io. - about once every 2.5 minutes at occasions - 336 times in a day - so every 4’17" on average - and makes up about 5% of my logs.
version.home-assistant.io appears once every 2 hours - which is more reasonable.

The TTL for the domain is set to 5 minutes:

2024, this is still a problem, [checkonline.home-assistant.io] as been blocked in AdGuard.
My HA work offline 99.9%, i do not need those constant phone home calls.

This randomly started happening to me. I was LONG overdo for update, things seem fine, finally add HACS everything seems fine. then suddently phiole just flooded w/ ‘supervisor’