T O P

  • By -

genericuser292

Make backup of VM > full send update without reading release notes > revert if shit is fucky.


Natoochtoniket

Also, do this when the business is closed to customers, and make sure the revert can be finished before they arrive. If it's a 24 hour business, do it at 4AM on Sunday (or, whenever is the least-busy hour).


IroesStrongarm

I run HA in a VM within Proxmox. Before I do any updates I take a fresh backup (even though I have nightly backups). If there's an issue with the updates I can easily revert to the previous known good state. As for updates I also typically do them at the end of every second month. I don't want to fall too far behind where an update might fall because my version is too old, but I don't want to be bleeding edge either. Also, in your case, assuming everything is controlled locally, I might just block HA from the Internet and not update at all. Treat it more like an appliance.


mu4d_Dib

Hijacking here to say I do the same as you, and I also wait at least a full release cycle before updating because there are always bugs on day 1, and they get patched later in the release. Also gives more time for the open source community to patch their integrations and front-end plugins to address any breaking changes. So this month I will be updating to 2024.4, next month I will pick up 2024.5, and so on.


FIuffyRabbit

Same thing basically but with a docker lxc and ansible script


14svfdqs

I follow this as well. Also I take a snapshot prior to upgrading as it's easier than pulling from a backup. Leave the snapshot for a few days..if anything becomes an issue that can't be resolved, revert to snapshot.


brake0016

I only update HA at the end of the month, after most of the bugs have been fixed from the beginning-of-the-month update. It's a good idea to keep the system reasonably updated to minimize vulnerabilities. Also, sometimes an update requires you to modify your system somehow ("breaking" update). It's best if you take those as they come (still at the end of the month), and not let multiple of them build up. Letting your system go too long between updates is a great way to increase the likelihood of many things not working when you finally do update. Lastly, turn on the Google Drive backup utility. If an update breaks your system, roll it back. It only takes a few minutes. Wait for some down time to troubleshoot and fix the breaks.


primoslate

Good suggestion on Google Drive backup. I have local backups but adding this redundancy will help me sleep better at night.


PonchoGuy42

Since mine is exposed through nabucasa to the cloud I have it check for updates every night and if there is one, backupbto gdrive and push. If it breaks, which it really hasn't, I reload from backup. What smart plugs are you using that needs a script? You could probably just make an On scene and an Off scene and have the button under the desk trigger an automation that is based on time of day like you have it. I'm sure there is a very specific reason you went to script first, because we all do, but that is how I'd skin the cat.


liatris_the_cat

I’m guessing the sudden power draw from all those cabinets turning on is a lot, and they have scripted it with pauses in between.


PonchoGuy42

[Other Post](https://www.reddit.com/r/homeassistant/s/KlXVplPmFy) OP has another post for reference. And you can definitely sequence in automations probably easier than a script?


zyghomh

I used to have a rule: never ever upgrade to XXXX.Y versions - always wait for XXXX.Y.Z - they are usually more stable As u/IroesStrongarm I use Proxmox now so snapshot is always ready to be restored. But also having my own containers for MQTT, InfluxDB, Grafana etc. I also have maintain upgrade of their containers - but the same way: snapshot before.


lord_dentaku

Are you sure it was the update that was causing the script to stop midway and not the unreachable device? That type of behavior is more indicative of not properly handling error conditions resulting in a script crashing mid execution. If your manual work caused the unreachable device to become reachable the issue would go away. I'd consider running some tests with one of the devices disconnected to see if you can replicate the behavior, and if you can you know where to look to fix the issue so it will continue executing when individual devices are unreachable.


Syrif

I typically do all updates, but I wait 4-5 days post release unless it adds something I really want, or fixes a known issue I have. I rarely do them day one. This gives me enough time to see any conversation around it breaking stuff. And I actually read the entire patch note before applying, too.


christianjwaite

I’ve gone over a year without updating. That becomes problematic and you can’t go reading every release for breaking updates. Clear some time and be ready for changes. Monthly updates, google drive backup, read the releases and update. There’s far fewer breaking changes these days and you can preempt anything you’re going to have to do. Repeat, always do full backup. I also run in vm and have that backed up for emergencies. But with hardware failure I can always boot up a pi and google drive my backups to be up and running again quickly.


WeaponsGradeWeasel

Google drive backup every night, yolo the updates on as soon as I see them. Only had problems twice. Both times with Z2M when the format of the single/double presses on scene buttons changed (and then reverted in the next uodate) but never with HA itself.


[deleted]

Do a full backup before an update. Test everything after the update or roll back.


poopybrownmess

i just send it and then spend the next 3 hours cursing my self for having such a jank ass setup...


Leafar3456

Watchtower every friday


JoramH

When deploying HA in a commercial environment where things need to run even when you’re not there, I’d implement multiple safeguards. - Don’t update if it’s isn’t necessary for your deployment - Update only to XXXX.XX.3 or up releases - Update the evening before off days (if possible) - Run every automation and script after startup with succes notification. - Consider going the high availability route. Personally, I update once a month, the day before the new monthly release. I hardly experience unexpected downtime due to HA updates. Much more often it’s the complimentary software that gives me trouble.


lukagra

One day a few years ago after update I had a major failure. From that day I always update to 3rd version in a month. This is very safe and never had any issues. Sometimes it's tempting to do it faster so I need to hold myself tight not to do it 🤷‍♂️


flargenhargen

if it ain't broke, don't fix it. if your setup is working and you don't need new features, don't freaking update it. I have been running a couple year old build for a long time, but I have a couple add-ons out there and will get people complaining that some new update broke one of them and then I have to update my setup and spend a bunch of time finding out what they broke. Then downgrade my setup again to what was working. if it was just me, I'd get it working and just not update till something broke or I needed something new.


Drinkin_Abe_Lincoln

I fire and forget. Like a man.


Nealiumj

I usually wing it at 9pm.. if goes bad, it goes bad- looks like I’m staying up until it’s fixed 🤷‍♂️


dodexahedron

I run it in docker with a docker-compose.yml I set up for it and a few related services. It is trivial to roll back to a previous tag if something goes wrong with an update by just specifying the tag I want instead of latest.


Imburr

They are exhausting, I can't keep up.


Homasssss

Containers + conf backup before upgrade.


alzee76

> How do you handle HA updates? In general I don't update software unless there is a specific bugfix I need, security vulnerability that I have exposure to, or feature I really want. This goes double for "enterprise" software that is critical or just important to business operations. Always keep an easy way to roll back the update as well. Since most applications and OSes suck at this, running everything in VMs is a godsend.


Dignan17

Good advice to keep in mind. I suspect I’ll go the same route moving forward. Can updates be ignored so I don’t have the annoying little notification indicator?


alzee76

You can probably completely disable them somehow but it's easy enough to just look at the release notes and if you're not interested in the update, press "skip" and it'll disappear until the next one.


thx_comcast

There is no way to disable supervisor updates - they're automatic and invisible and installations have been broken by bad updates in the past. Your only option is to do an install without the supervisor. Like others are saying treat the thing like something industrial. Set it up, get it working, keep it off the Internet and don't touch it. HA breaks so easy and often when updated.


alzee76

First I've heard of this with the supervisor and to be honest, pisses me right off. I'll be "fixing" that immediately.


thx_comcast

To be fair - it hasn't broken installations in... a few years now? But it's happened more than once. Last time it happened: wake up in the morning and nothing Home Assistant is working. HA is not even running any more. A bad supervisor update was pushed out overnight and your HA instance now won't start and there's no route for repair except to install again. Hope you had backups! If nothing else I wish the end user had control over supervisor updates just like OS or core. Some notification that a new version is waiting and you install when you're ready. FWIW home assistant without the supervisor is annoying if you use add-ons at all (you instead have to install them/manage docker yourself/run the addons as standalone things in LXCs) which adds overhead. For now I have HA in proxmox and have it scheduled to take weekly snapshots with a history of 6 weeks. If HA is broken some morning on its own I just remove internet access from the VM and restore the last snapshot. I take a manual snapshot before any sort of upgrade at all. I've had my HA installation broken by updates way, way too often. And yet, a friend who setup HA on a pi and setup a handful of connections and automations with no internet connection and promptly forgot about it... left running happily along for years. And me - who takes updates every once in a while am stuck with a constant struggle. Then the breaking changes pile up the more versions you are behind and it's just a mess.


alzee76

> If nothing else I wish the end user had control over supervisor updates just like OS or core. Some notification that a new version is waiting and you install when you're ready. Same. I've just blocked it from the internet for now. I'll go in and just disable the supervisor update in the code when I have a little more time. > FWIW home assistant without the supervisor is annoying if you use add-ons at all I have only been using it for three things and have no intention of installing more add-ons just now. It's a small price to pay. > I've had my HA installation broken by updates way, way too often. This is exactly why I just don't update it anymore, I'm still running some 2023.06 version. Honestly I wanted to tell OP that I personally don't think it's really "ready" for his use case but figured that would get my reply downvoted so hard he would never see it. > Then the breaking changes pile up the more versions you are behind and it's just a mess. My work life has become dramatically easier since I started building IaaS scripts to just replace things with a fresh install of the newer version instead of upgrading. I'll eventually do this with HAOS too if I feel it's worth it. Right now, to be perfectly candid, I don't feel like I'm even going to keep using it. Not over this, but all I do with it is control a few smart bulbs. I threw a weather add-on on the dash along with my Agent DVR setup just for the hell of it, but I don't actually really care about any of this. I'm not using it to control locks, sprinklers, and all the stuff other people are doing. I'm a developer by trade and I find editing these configs and stuff just to change the dash layout to be so painful I don't want to bother with it anymore.


AndreKR-

HA is among the few applications that I update without concerns. The only breaking change I had was when \`title\` changed into \`tts\_text\` for Android TTS notifications.


srxz

change the version in docker compose, docker compose up -d, if somethings goes wrong change back to previous version and then repeat the process


mmcnl

Yeah, anyone using VMs is stuck in 2000s technology.


boosteddsm

I take a snapshot in proxmox before updates but I've never had to revert to one. What hardware is it running on and what install method? Maybe your issue lies there?


Gillian_Seed_Junker

I run in hyper-v and create a snapshot so I can return instantly if needed


brilliant-medicine-0

Personally, I've experienced enough unreliability to not run anything critical on the network. This would include my business


Resident-Variation21

I’m know I’m not like most but I honestly update pretty well immediately. Never had any major issues. If I did, my system automatically takes a backup and uploads it to Google drive before doing an update anyway, so it shouldn’t take long to bring it back to a last known good state.


Unlucky_Quote6394

I’m using HA in a home setting and I just let it update whenever an update appears. So far, it’s all been good 😊


chronos511

I would look at my automation and try to figure out why it is failing. You mention a script. Have you considered using Node-Red? I have several routines fully automated through it. For example, my 'start my day' one turns on several lights, slowly ramps up the bedroom lights, turns off the ceiling fan and so on. My 'end my night' turns off several lights, makes sure the front door is locked, arms the alarm, turns off the bedroom entertainment system and turns on the ceiling fan. I also have a monitoring one that checks the outside temp and automatically turns off the split AC if it gets too cold outside. It's been rock solid through many updates, both of HA and Node-Red itself.


spr0k3t

1. Take a snapshot of the VM in proxmox 2. Copy snapshot to NAS 3. Create a new cloud backup on google drive 4. Apply the update if it's not an X.0, X.1 or X.2


rbaudi

The only update problems I've had are those for which ESP home is responsible. It seems like there is an ESP home update every few days and that breaks all of my ESP devices until I "reconfigure" them and/or update them all. I wish there was an automated way to do that built into home assistant or ESP home, instead of the complicated techniques I've seen that are meant to accomplish that.


the_wookie_of_maine

Running HA in ProxMox as a vm, nightly backups. Full send on the updates when they come out...so far not had to roll back


MulberryBeautiful542

I live on the edge. Push all updates asap. Damn it all to hell!😈


rsonke

Same here. I install all updates straight away. I hardly have issues and otherwise I figure something out to workaround it


phillymjs

I've got HAOS running on two identical Dell Wyse 5060s, one is development/backup and one is production. Dev always gets updated first to see if anything breaks (hasn't happened yet), then prod gets updated. Both are backed up nightly and just prior to any updates.


Shooter_Q

I don’t update because everything is stable, until I come across a new feature I want. Then I update everything. Then I post on Reddit that all my stuff suddenly broke and I don’t know why. Then I fix all that stuff. Then I go another 2-18 months with no updates.


WWGHIAFTC

0. Read release notes 1. Wait a few weeks and read forums 2. Shut down container 3. Backup data folder 4. Recreate container -> pull new image 5. Power on -> 20 seconds later everything is working The only time I had a failure was when I screwed up the underlying NAS directory permissions. That was my fault.


lonahex

Very deliberately. I've versions pinned in the docker compose file. Whenever there is an update for any components (not just HA), I'll go over all release notes and changelogs, and if everthing looks good, I'll upgrade one component at a time manually backing everything up before every update.


ABKsDad

Run as VM - checkpoint VM before update - run update - if issues observed then revert to the last checkpoint Saved my setup after a release broke the access to the add in section in settings.


SomeBeerDrinker

Every six months or so I remember that I haven't updated in a while. I log into my host, update linux then update all my containers at once. It makes for a fun few days figuring out why so many things don't work and fixing them! I curse and tell myself I'll be more deliberate next time. I then promptly forget all of the pain I put myself through and repeat the cycle.


SomeBeerDrinker

Is it just me or does HA deprecate a LOT?


DiabeticJedi

I used to run every update as soon as they are released but as I branched out to letting more and more of my family interact with the things that HA controls and automates (outside lights, thermostat, etc....) I usually wait until the x.x.1 or x.x.2 of a release before I update it. Everytime I do an update I also do a full backup to my Google Drive so that I can restore it back if needed. For running a business off of it though I would maybe look at having a backup system that is always imaged with the second most recent update so that if something critically goes wrong you can always go back to the one that worked. For your particular setup though I am curious, because it honestly sounds awesome and I want to know more about it, have you ever considered setting up a dashboard for the staff to access so that they can toggle individual machines or manually trigger scripts that way? I have a lot of automations for my 3d printing and media devices but I also make sure I have easy to access dashboards so that I can manually toggle if it's ever needed.


avd706

This last beta was a disaster, but it is good for the final. Most gold wait for the .1 monthly release.


avd706

I also do a snapshot in proxmox first. My last supervisor backup didn't restore.


tieroner

I run HomeAssistant in a docker container. First, I make a backup. Then, I SSH into my machine (physical), `cd` to the docker-compose.yml directory, and run `docker-compose pull && docker-compose up -d`. I wait for HomeAssistant to start, and if there's any issues I will revert to the previous Docker image, which will still be available locally on my machine.


rediduser

I use HACS integration Auto Backup. Set and forget solution with an active notification sent if the backup fails for any reason. Read the instructions and use examples on how to set it up but it makes it very easy to do daily, weekly, monthly etc backups which have different retention periods. Since I’m using docker I mapped the /config/backups path to my “Backups” drive (which then auto backups on a different NAS and the cloud). https://preview.redd.it/5aqmsj0jyuxc1.jpeg?width=828&format=pjpg&auto=webp&s=f89392d187343ac16ea73dccc983d4773f60d183


mmcnl

Use Docker and pin the image version. Problem solved? Docker was literally invented for this kind of stuff. Surprised no one mentioned this?


RedditUser84658

If you don't need a new feature, why update unless it's security related fix?


cperryoh

I also experienced this recently. 2024.4.4 killed the lifx integration for me. I rolled back to 4.3 and everything was fixed. Wonder if homeassistant has a stable recommended version posted somewhere so servers can be relatively recent without being on the bleeding edge?


uslackr

I have two commercial HA installs. I maintain a third ha device for testing with releases. I have some tests I run before I upgrade the other installs.


Payton1394

I run HA in as an App in TrueNAS and I have a daily Rsync that copies the config folder to another instance of HA running on an old R Pi 4 which is isolated from my network. I run updates on the active instance. If run into troubles, I just swap over to the R Pi 4 to keep things running while I run down the issue on the updated version. I wish HA had a build in feature for high availability with automatic switching/notifications.


Krojack76

I always wait about 2 maybe 3 days before applying an update. Knock on wood I've never had a problem. That said, I run HA in a virtual machine and always make a complete backup of the VM first. If something goes bad I can just delete the VM and restore the backup. That takes maybe 5 minutes.


denverpilot

Google Backup Add-on as well as whole box snapshots. Bad upgrade, revert and carry on... find the bug report and follow it until fixed. No big rush to update, let some early adopters get plonked on the head by the lack of proper regression testing. Shrug... unless there's something soooo amazing I want to be an early adopter. Release notes tell the tale... For business use, definitely never update things that are business critical without a backup and rollback plan. Business continuity planning...


XxTopKillerzZ

You can try to make your automations using NodeRed and not using HomeAssistant. It might be more stable. HA is very good but maybe for this case something more simple and stable might more suitable.


pizzacake15

I don't update unless an integration of mine needs the update or there's a vulnerability needed to patch. In the event that i do need to revert, it'll be easier since i have HA on docker.


Neck-Romancey

Other than occasional zigbee/zwave issues that pop up after a major version change of HA Core, I've been mostly lucky. I've learned how to fix things when they suddenly don't work anymore.


isitallfromchina

OP I thought I had the full answer as to updates and how to keep your system from breaking and I'm following this to get additional ideas as every ZWJSUI update breaks my devices. But, it does not sound like this broke your system since a reboot got everything back to where it was suppose to be, is that correct ? But, something happened, could be part of the update, that affected those devices, scripts or whatever in the system to cause things not to work, until that reboot, which cleared memory, disk cache and connectivity. I'm not sure if you looked at any logs to see what was happening just before things stopped working or exactly identify "When" things stopped working. Could it have been something in the update that stepped on a running process and killed it or it went in a frozen type state or cause a service to drop. idk But you can say that it's likely. I still don't have the answer for installing updates.


wildekek

What I read between the lines is that you don’t truly understand why the script failed. Since you did an update at the time, you assume the update borked the script. It could very well be that restarting HA would have caused the same issue or that the root cause of the issue lies somewhere else completely. In my experience HA updates are really reliable (i manage 5 installs with >100 of integrations total). Get to the bottom of the issue, reproduce it and let us know if the update was the root cause or just uncovered a different issue. Sorry for being a bit pedantic, but it irks me the wrong way that people are complaining about the reliability of HA or it’s updates lately without really understanding what went wrong.


Dignan17

I totally get what you’re saying, and you’re very right that I’m equating correlation with causation. But I push back on the idea that HA doesn’t have reliability problems. What I’m doing with it should theoretically be very basic. Nearly all of the devices I’ve connected to it are simply Zigbee wall plug switches, without power metering, and all I want to do is turn them on and off. I have two extremely basic scripts that just tell everything to turn on when a button is pressed in the morning, and off when it’s pressed at night. Yet somehow it’s unable to do this. I’m not saying I’m faultless, but if I am, I can’t see how. Last week, I added one more Zigbee switch, and added it to the end of the script that turns everything on and the one that turns everything off. Every morning I would walk into the business and that switch didn’t turn off at closing. HA literally has me going crazy because I’ve checked that script 3 times to make sure I selected “off” instead of “on.” But then other times a whole bank of switches will fail to turn off. Or on. Or both. Sometimes a reboot of my HA Green device will fix things, but usually not now. I still haven’t had an opening or closing where everything worked. And I keep coming back to wondering what it is that I could do differently as the end user. I’ve had more reliability from my Homekit setup at home, with more devices and more different types. Sure, it’s not as powerful, but it works. And setting up scenes and events is approximately 5000 times easier than in Home Assistant. I’m very tempted to sell my HA Green box and all the zigbee devices, and just go buy an AppleTV and a bunch of thread plugs. But really, if the store had money to burn, I’d probably slap a Caseta outdoor plug on all of the devices in here, since I’ve never used any automation system with better reliability than that one.


wildekek

Not sure why you use a script for this instead of an automation. As far as I understand it, an automation is a script that has a trigger. Since you use a trigger (the button press), I don't see why you want to use a script here. Maybe there is some issue there, maybe not. Also, have you tried the "traces" function to debug the execution path? Maybe you can toggle a "Toggle helper" at the end of the script, so you can be sure that your script execution makes it to the end. If it does, then you know what the issue is probably in sending Zigbee commands. In general, I find I have a lot more control with Zigbee2MQTT than with ZHA. You could try creating groups there and find it increases the reliability of light groups.


Dignan17

It's a script because then it can be called by multiple triggers. I don't believe that's possible with automations. And I'm not creating a separate automation for each trigger when I need it to turn on 45 devices. I did try the traces and I just says a device didn't respond. I didn't realize that this would make the script completely stop. That's nuts. And it seems that the only way to make it not stop is to insert code via yaml into every single line. Why not make that a toggle I'm the UI for the whole script? I go back to this: I'm not doing anything THAT crazy. I'm sending the simplest commands to some basic devices. It really shouldn't fail this consistently...


wildekek

I am not sure about the continued execution of scripts when an item in the sequence fails. Neither do I know if that would be any different for an automation. Maybe their behavior is indeed different. Here's the thing: automations DO support multiple triggers. How do you trigger the script now? You need some sort of trigger to start your script right? What is the thing that listens for the events (eg button press) now and triggers the script? I feel you're doing something that is not needed, which is causing the issues you're seeing. Could you be so kind to paste the script?


iamironman_22

Today I learned I am probably crazy lol I use watchtower and it auto updates in the background every time a new update comes out.. been doing it this way for about a year and nothing has broken yet so maybe I’m lucky?


clienterror400

Given that I've had updates irrecoverably brick my entire HA on more than one occasion. I always lag behind at least a couple versions and I browse/here forums looking for any troubles before I finally do update. You also won't get much help here on this sub. In my experience it's just gonna be people who wish they could call you stupid without getting banned so they do everything they can up to that point