Well, another catastrophe!

Y’all need a dummies category! Just put this in uncategorized :slight_smile:

Well, another catastrophe!
I will try to make this as short as possible and still give you all the information you may need. I have home assistant on a raspberry pi 4 that I just got a external USB 250G SSD drive and moved everything to it. I love it. Much better speed. But now I have messed up my configuration trying to use Duck DNS for remote access. (Watching YouTube videos) I added 3 lines of code in my configuration.yaml file, checked for errors with developer tools, NO ERRORS, and rebooted. It said it lost connection but never reloaded the UI. I powered it down and back up again, but the UI was down. All the lights and everything looked good on the Pi. I hooked up a monitor and keyboard to the raspberry pi and got a HA prompt.
My question is.
1 Is there any way I can edit the configuration.yaml file from the SSH HA prompt? (To remove the 3 lines of code)
2 Or do I have to start over with a backup?
3 Can I restore only the configuration.yaml file?
4 can you copy all of your yaml files from the pi to a WinPC? (And copy them back using SSH if need be)
5 Why did developer tools say that there was nothing to stop home assistant from loading? (Now I don’t trust it)

The 3 lines of code that killed me:
http:
ssl_certificate: /ssl/fullchain.pem
ssl_key: /ssl/privkey.pem

Info:
I did get Duck DNS installed with domain names and token don’t think I have everything done in port forwarding whenever I go to the URL I get my Mikrotik router
Keep all of home assistant updated
Keep home assistant backed up (but not after I did several hours of work on it today)
My total backups are roughly 300 MB
I have roughly 300 devices and 1500 entities
I connected my SSD drive to my computer but not a lot visible and no configuration.yaml file
there was only about 7 MB on it visible to Windows

I’m 63 years old and tried using home assistant about 6 or 7 years ago may be more. It was more than I could handle at that time. I watched some YouTube videos about it a couple of years ago and they made it look easy so I tried again. I couldn’t believe how far they’ve come making it more user-friendly. But I am still not much on code so I don’t do much other than watching YouTube videos.

Thank you for your time!
Dennis
HADummy

Well Thanks everyone. I am not sure what happened but the next day I tried pulling up my home assistant in a web browser and it came right up to a login screen. Not sure what magically happened overnight? I know I tried IP address and port, and also network name and port with both http:// and https://. It will not work anymore unsecured I do have to use https. And haven’t tried anything more about getting duct DNS working remotely I did get a sub domain name created.
But this brought up me a easier way to restore a backup when something like this happens that I should probably start in another post. The easiest way to clone a USB SSD that are identical?

Hi Dennis, are you running HAOS?

You can use the keyboard and monitor connected to your pi to edit the config file from the command line.

cd /config

nano configuration.yaml

EDIT:

also just to be sure, before you do that, you are using https rather than http to try and connect now aren’t you?

If you use https://<ip_address>:8123 or https://homeassistant.local:8123 you will have to tell the web browser it can add a security exception. The SSL certificates only work with your DuckDNS domain.

2 Likes

Yes I have tried all 4 ways ip, url, secure, and unsecure

But I will try editing my file before I try restoring a backup.

Sorry but I’m not too good at command line stuff. I am at a ha> prompt. And very limited on commands. cd (Change directory) and nano (File editor) will not work there.

Yes,64 bit

I use a Cloudflare tunnel, much easier to set up, but you need a domain name for that.