home-assistant / core

:house_with_garden: Open source home automation that puts local control and privacy first.
https://www.home-assistant.io
Apache License 2.0
70.16k stars 29.18k forks source link

Restart 2023.11.3 fails #104561

Closed mjpsr11 closed 4 months ago

mjpsr11 commented 8 months ago

The problem

Finally got 2023.11.3 to install (after several failed attempts) and all seems working fine. I only changed from logger: debug to logger: info in conguration.yaml. Upon restarting from Developer tools> YAML> RESTART, if reaches waiting for sun integration, then fails to proceed or respond.

What version of Home Assistant Core has the issue?

System Information version | core-2023.11.3 -- | -- installation_type | Home Assistant OS dev | false hassio | true docker | true user | root virtualenv | false python_version | 3.11.6 os_name | Linux os_version | 6.1.59 arch | x86_64 timezone | America/Chicago config_dir | /config
Home Assistant Community Store GitHub API | ok -- | -- GitHub Content | ok GitHub Web | ok GitHub API Calls Remaining | 5000 Installed Version | 1.33.0 Stage | running Available Repositories | 1343 Downloaded Repositories | 34
AccuWeather can_reach_server | ok -- | -- remaining_requests | 3
Home Assistant Cloud logged_in | false -- | -- can_reach_cert_server | ok can_reach_cloud_auth | ok can_reach_cloud | ok
Home Assistant Supervisor host_os | Home Assistant OS 11.1 -- | -- update_channel | stable supervisor_version | supervisor-2023.11.3 agent_version | 1.6.0 docker_version | 24.0.6 disk_total | 30.8 GB disk_used | 10.8 GB healthy | true supported | true board | ova supervisor_api | ok version_api | ok installed_addons | ESPHome (2023.11.4), Terminal & SSH (9.8.1), File editor (5.7.0), Duck DNS (1.15.0), Home Assistant Google Drive Backup (0.111.1), Mosquitto broker (6.4.0), MQTT Explorer (browser-1.0.3), rtl_433 (0.4.1), rtl_433 MQTT Auto Discovery (0.7.0), Samba share (12.1.0), SQLite Web (3.9.2)
Dashboards dashboards | 4 -- | -- resources | 25 views | 10 mode | storage
Recorder oldest_recorder_run | November 16, 2023 at 10:54 PM -- | -- current_recorder_run | November 26, 2023 at 12:50 PM estimated_db_size | 198.04 MiB database_engine | sqlite database_version | 3.41.2
Sonoff version | 3.5.3 (a8c6d45) -- | -- cloud_online | 2 / 3 local_online | 2 / 2

What was the last working version of Home Assistant Core?

2023.11.3

What type of installation are you running?

Home Assistant OS

Integration causing the issue

No response

Link to integration documentation on our website

No response

Diagnostics information

No response

Example YAML snippet

logger:
  default: info

Anything in the logs that might be useful for us?

Starting Sun, not everything will be available until it is finished.

[Restart freezes at this point.]

Additional information

No response

erwindouna commented 8 months ago

It's very unfortunate this happens. Are you able to provide us with a bit more information? What would help is to share the debug logging you're capturing. Or maybe your Configuration.YAML (might be a typo has slipped through).

mjpsr11 commented 8 months ago

home-assistant.log

Here is the log file. I'm afraid there is no help here. To recover, I have to attempt restart of core with this command [ha core restart] at least 3 times before it is successful. Each time it stalls when waiting for the Sun integration (however, I think that is just the last notification before it crashes.)

BTW, this happens with just a simple core restart and no changes.

erwindouna commented 8 months ago

Have you tried removing the Sun integration and then try to catch the logs?

mjpsr11 commented 8 months ago

I removed Sun integration, restarted just fine. I added Sun integration back and restarted again just fine. Not sure the problem, but seems to be resolved.

erwindouna commented 8 months ago

The good news is that it's resolved. It's odd behavior, nonetheless. Maybe try to close the issue if you deem this properly solved, or start a new issue if this occurs again. Hopefully you can provide as much logging as possible when it does. :)

mjpsr11 commented 8 months ago

Final note. Sorry about reopening/closing.

I realized that Sun integration is part of default_config and despite removing it, it was automatically added for restart. I then removed default_config and added all the default integrations needed (except Sun), but still have the issue of a 'non' restart.

Now it gets stuck at a random integration. Again, no help from the log file (only warnings about custom integrations not tested).

I decided to remove the sqlite db. Once I did that, it automatically restarted. Of course, I lost my history, but seems the problem was a corrupt db.

mjpsr11 commented 7 months ago

Thought that a specific integration may be causing my startup problems, but it fails even when uninstalling the Sun integration. So that doesn't seem to be the problem.

The failed restart doesn't seem to have any consistent indicator (i.e., sometimes it starts and other times it doesn't).

It seems to be hanging while initiating integrations (as far as I can see). I'm attaching the latest log and a screenshot of the integrations screen when it hangs. Based on the screenshot, it seems maybe the Google Assistant integration is causing the problem, however it will ultimately restart with no changes to any integrations, including Google Assistant. Is there a way to add more debug info to the logs for initializing integrations? home-assistant.log Screenshot 2023-12-08 090954

Hopefully this is helpful to troubleshoot.

erwindouna commented 7 months ago

What seems consistent in your logs is a timeout on 192.168.86.22:5555. Do you know what device this is?

mjpsr11 commented 7 months ago

This is a device in the Android Debug Bridge integration. It's a firestick. This warning shows up because the device is powered off (i.e. timeout while trying to connect). This warning clears once I power up the device (it's not always powered).

This is not the problem.

mjpsr11 commented 7 months ago

I've had to downgrad to v10.5. All versions of 11 give the same problem and the last time I had to do a complete re-install. Unfortunately, I have not found a better way to troubleshoot the problem other than trial/error by removing integrations/addons one at a time. Please advise if there is any other way to troubleshoot (i.e. specific log configuration, etc).

issue-triage-workflows[bot] commented 4 months ago

There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates. Please make sure to update to the latest Home Assistant version and check if that solves the issue. Let us know if that works for you by adding a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.