No access more... all forbidden!

403: Forbidden
after changing the configuration.yaml
and banned_ip

I had a defective computer in the local network from which I controlled my home assistant. I then tried to give another PC the opportunity to log in to the homeassistant server. This then got Forbidden… then I deleted the entry in the baned_ip,
Since this didn’t help, I deleted the file and added the allowed IP range in the configuration.yaml.

I think I’ve totally done something wrong.
Now I can’t log in at all… I can’t even log in from my cell phone, which always worked.

I only have the Homeassistant-OS command line directly on the server…

What do I do to be able to log in again?
can I restore a backup there?

Did you restart after updating the ip_bans.yaml file?

yes i restart homeassistant

i need any command to restore any backup , because then i can loged in again from mobilephone

command for the command line

is there no one here who can help me?..

It would be great if someone could help me here otherwise I would have to reinstall everything and that would be a disaster

I’ll get to the HA command line.
I can also list the backups there
Unfortunately the command " | more " doesn’t work and there are probably over 100 backups going through so I can’t find the right one.

I need help with the commands here please.
For

  • Page-by-page listing of backups
  • Backup restore

I just did a full backup a few days ago…
But I don’t remember the exact name

I need this backup and would like to restore it from the command line

Hi, can’t help you on the restore issue.

On the CLI, you could try by using nano to modify your configuration.yaml and change the ‘ip_ban_enabled’ to ‘false

ls -lt

shows last modified files first.

`backups`  will list all of your snapshots. Take note of the “slug” for the snapshot you want to restore.

`backups restore -h`  will give you the parameters you need to pass to restore a given snapshot.

`backups restore [slug]`  will restore the snapshot in its totality. You may want to check the  `flags`  options available if you don’t want to do a complete restore.
1 Like

but that sounds very good…
I didn’t even know that there was Nasno in the HAOS installation…
Currently I should be on the command line in the config directory where the configuratoin.yaml is

I had already found these commands here in the forum… but I couldn’t really figure it out

because

  • snapshots ===> list everything and too much
  • snapshots | more ==>
    do not stop the listing page by page

and
snapshot restore [slug] ===> mmmhhh I didn’t find any examples that showed me how to restore a backhab with flags

  1. I need the name of a backup first, right?
    To do this I would have to stop listing snapshots page by page to see which backup I need… or am I misunderstanding that?

I’m not using ssh on the Raspberry with HAOS.
I connected a monitor and keyboard directly to the Raspberry and now see the slimmed down HAOS version in front of me… which is unfortunately so slimmed down that very little is possible there

But I don’t know all that exactly… which is why I’m asking for help here

If you attached screen and keyboard, then first enter

login

and then
afbeelding

1 Like

yes and exactly that screen i miss…

and he doesn’t know any “ls” or “cd” there either



okay… sorry … i don’t know it i have to login first… i think i logged in already…

ok, i listed now my backups… i think the first on the top is the right backup from my last fullbackup… i use in home-assistant a other name but i think that is it…
what i have to do to restore that now?

and what do I have to do to enlarge the display on my screen… I suspect the resolution is extreme and I have to look for everything with a magnifying glass because it is displayed so small

is this
`backups restore 04872cb8.tar ?

No idea, I think it takes the resolution from your screen

Now you type

exit

and then

backups restore 04872cb8
1 Like

okay… i think that works now… becaus is on ptrocessing…

perfect… thank you a lot… you make now weekend now quiet… i hope the backup clear that problem…

where i can find my right username ?

After installation, I always logged in automatically in my computer’s browser. It was the same in the cell phone.

Now my computer crashed and I forgot my login name…
then I got banned because I had logged in incorrectly too many times
This then led to the incorrect settings being set as permitted ones in the configuration.yaml.

Ultimately I think that I always entered the username incorrectly… I know the password… unfortunately I don’t know the username and I didn’t read it in the configuration.yaml either

it should be in the file auth in /mnt/data/supervisor/homeassistant/.storage

(need to login again)

ok i try to find it

the backup restore is done

but i can’t login
i try now to find the configuration.yaml
and now im in root directory… i see the etc and other directorys… whare i can find the confog ha-directory ?

/mnt/data/supervisor/homeassistant

i find it now thank you
but he not finde the nano editor
wow. thats complicated for the first time command line