Can I restore my broken config with just this?

Okay so my last backup is from two days ago. But I spent the following days making some new automations and adding a new sensor. This morning I was reading a thread on custom UI cards, and apparently the single frontend line broke my configuration.yaml

Couldn’t putty, couldn’t samba, nothing.

So I used a linux reader to mount the card and copied the entire docker files.

So I have these folders: addons, apparmor, backup, homeassistant, share, ssl, tmp.

Can I restore my setup? How? Just by copy pasting everything after a clean installation?

Thanks.

Note: I don’t have a linux box. Just windows.

I think the config yaml files will be in the homeassistant folder… so I’d extract those and then do a clean install, restore backup and copy back yaml files…

It is. But there’s much more than that; like the node-red flows and z-wave network

Why not just fix configuration.yaml in the home assistant folder? That is a better idea I think…

I actually tried already doing a clean install and using my latest config yaml and it was missing the new sensor (not the config file, the actual sensor is not included in the network), not to mention I’ll be missing my new node-red automations

I mean edit it on the sd card that is currently broken… if it’s just the frontend line just fix that and put it back in the pi

oh the application I used didn’t allow me to, it was read and back-up only. It was DiskInternals Linux Reader. I don’t have a linux box.

Install VirtualBox, then install Linux Mint. Easy peasy! :slight_smile:

https://www.virtualbox.org/

https://www.linuxmint.com/

Or you can just setup your Windows PC for dual-boot. It’s actually pretty easy. Install Linux Mint, and during the install process you can select the dual-boot option. That’s how I have one of my laptops setup which I use at home to interact with my Pi. It’s worth the effort.

1 Like

I will give this a look! Thing is … After copying the docker, I formatted the original card. Were I to just flash it again, look for the docker I replaced and copy and paste the old one on top… it should work, shouldn’t it?

If you’re asking me, I don’t use docker so I’m not familiar with how that works. Sorry. I was commenting more from the perspective of easily setting up a “Linux box” you can use to mount the SD, edit files, etc.

This might be usefull regardless, I shouldn’t have formatted it so soon. I will give a try just force shoving all I copied in.

Yeah… I don’t know if you can just copy it back… hopefully you can… You can also download gparted and it will give you a linux boot with a terminal you can use to edit and mount the partitions without installing anything on your PC. I have mine on a cd so I can boot it…

where did you have your docker container setup to look for your config directory? it should have been the line that said “-v /some/path/on/host:/config”. the /some/path/on/host is where you’ll find the config files.

I’m very confused about how that question is phrased, I’m not sure what you’re asking.
But here’s an update:

So I mounted linux, I then mounted my SD with a clean hassio and an USB with the old docker data. I located the same folder structure contained that I backed up in the USB and replaced them with the old files.

And it works! Perferctly! Excepto for node-red… for some extrange reason the hassio palette add-on appears as “installed” but it isn’t in the node list anymore, and it’s breaking literally all my automations.
All the nodes read “unkown: api-call-service”. I tried restore just node-red from other backups and no dice.

I give up! I’m just going to restore a previous functional backup and recreate the missing automations with the bits I can salvage without having to touch the hassio installation.

yeah, nevermind. I didn’t realize you were using hassio. thought you had it set up in a regular docker.

I actually recently had the same issue after adding a line into my sensor.yaml file. After a bit of research, I found a better solution than reflashing the entire home assistant… Even if you don’t have ssh enabled.

I found a software called “Linux files Systems for Windows by Paragon Software” (Linux File Systems for Windows | Paragon Software), that emulates ext4 drives with reading and write rights in Windows. After starting the software you just conveniently access the configuration files like any other hard drive in windows and revert everything to a working state.