Rant about constant maintenance of HA (changing entity names among other things)

Hi. Sorry for the rant, but i am fed up with the amount of effort needed to maintain my HA instance.
I had HA for about 5 years now, and I genuinely enjoy tinkering and adding new things to my instance. I got to a point where I’ve got over 250+ devices connected to HA and several thousands entities. I don’t think that’s a lot, but got to a point that maintaining the existing configuration - just to keep it fairly working, became a full-time job on its own, not to mention actually making new automations with using those entities. And i don’t mean breaking changes between different HA upgrades, or third party providers changing something - that would be fully understandable. What i mean are entities duplicating themselves, changing their names, going temporarily unavailable/unknown without any apparent reason, etc. Just yesterday i have deleted over 1000 unavailable entities on my HA instance. Today, i was investigating why i have lost my sensors in the dashboard just to find them with _2, _3, or even _4 suffixes. Ultimately whenever i find some time to tinker with HA, instead of making new automations and other cool stuff, i end up fighting fires coming from entities getting randomly renamed or missing.

Often random people who are curious about my set-up, ask me “How stable is Home Assistant?” and i genuinely dont know what to answer them. The software itself is very, very stable nowadays, but the way it handles integrations constantly causes problems.

I am really hoping that HA devs will address this somehow. Im not sure how, but that is something what should and needs to be addressed.

Hi,
Changes do occasionally happen, but I’d suggest the last few years have been improving consistency, and more importantly, detecting issues before they become problems.

Personally, I appreciate the efforts to make HA more self-healing (repairs have been good for me), and the (entirely optional) time spent to update my automations.yaml syntax did flush out some cruft and pay down some technical debt.

There have been some significant database improvements in the last 2 years, and although I had already cleaned-up my long-term statistics manually (YT video from Beaded Tinkerer on maintainance), the clean-up is now an automatic part of HA and a repair.

If you’re having issues with deviceIDs and entities:

You can also add an extra layer of consistency checking if you install HACS2 and Spook (detects non-existing entities and reports with a Repair):

If this helps, :heart: this post!

1 Like

thanks for the tips, i already know Spook, but rarely manage to get to less than 30 issues detected at same time.

Another issue has just happened: ive got identical air quality sensors in each room, each reporting several values - and all entities were named sensor.<room_name>_. Six hours ago (according to HA history) all the PM2.5 entities were renamed just to: sensor.pm2_5_concentration_1, sensor.pm2_5_concentration_2, sensor.pm2_5_concentration_3, but all other entities were unaffected:

Even with a small house moderately saturated with sensors, things like that are happening literally on a daily basis, regardless of integration :frowning:

This sounds like an issue with the integration more than HA core itself.

1 Like

Well, two of the most problematic integrations (where this happens most often) are MQTT and ESPHome. But i get what you mean, that’s why its always so hard to answer “Is HA stable?”, because it is.

But my point is - HA could handle it better. For example if an entity disappears (goes Unavailable) and at the same time a new, similar entity shows up, instead of adding _2 to the new one, lets put the new one first and add _2 to the old one

That occurs when the unique_id changes. Either you changed it in yaml or you have an issue with an integration. Is this occurring for entities created by a particular integration?

That should not happen. Again, possibly an issue with an integration. Is this occurring for entities created by a particular integration?

There is always a reason. Most likely the stability/suitability of your network or wifi access point or mesh network if using zwave or zigbee.

  1. Which hardware layer (Ethernet, zigbee, zwave)?
  2. What wifi hardware access point are you using and how many devices are connected?
  3. Have you read the zigbee Community guide about minimising interference?

The other reason, cloud resource stability, is beyond your control. e.g. I have a rest sensor and a command line sensor that both rely on (separate) cloud resources. These go unavailable occasionally through no fault of Home Assistant.

I have spent whole weekend housekeeping. Updating HACS integrations, corresponding sensor name changes and then updating automations. Spook has done a great job of reminding where I have orphan cards. In the meanwhile HA has not missed a beat and has not changed anything. All changes are coming from non-core integrations.

That occurs when the unique_id changes. Either you changed it in yaml or you have an issue with an integration. Is this occurring for entities created by a particular integration?

Most recently MQTT, ESPHome, previously also Zigbee/Zwave - but with those i blame changing variable names/units between versions of Z2M/ZwaveJS (for example sensor.something_something_energy_kwh changes to sensor.something_something_energy_consumption_kwh).

  1. What wifi hardware access point are you using and how many devices are connected?

around 50 wifi devices connected to 2x Unifi AC-Pro. Similar things happening with ethernet devices too.

e.g. I have a rest sensor and a command line sensor that both rely on (separate) cloud resources.

I never said that HA is responsible for the underlaying issues causing problems. I say that HA should get better handling them (because network/cloud/etc issues were, are and always will be happening).
A could of days ago i have updated my ebusd container - the downtime was maybe 1 minute, but that resulted in several hundred of entities (MQTT integration) needing to be renamed in HA as they got duplicated with originals going unavailable.

What is generating the MQTT discovery messages?

I get rediscovery devices on Bluetooth integrations a lot (Inkbird, Govee, & Oral -B). As long as I hit ignore no duplicate entities are created. The other one for me that constantly creates new devices is Ibeacon tracker. No idea how to fix this one. I have not seen any duplications on MQTT in a long while.

Hi Tom, everyone.

As an end user, I too have had issues with entities being renamed (most recently with AlarmDecoder, but it has happened multiple times). This does happen. It may not be an issue generated by the core HA code, but we all depend on integrations.

When this happens, multiple pages break, automations break, etc…

I understand that the folks here spend hundreds of volunteer hours to maintain a code base. Also, users spend 10s of hours to build a system, and sometimes they get frustrated too. I hope we can focus on the issues and let some of the delivery style (on both sides) roll off our backs…

1 Like

As that is a core integration you should open an issue for this here: Issues · home-assistant/core · GitHub

If it happens with a third party integration then open an issue in the developer’s repository.

This is how these things get fixed.

1 Like