Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Home Assistant becomes unresponsive with newest zigbee2mqtt add-on version. #609

Open
chheiss opened this issue May 10, 2024 · 40 comments
Open

Comments

@chheiss
Copy link

chheiss commented May 10, 2024

Description of the issue

Home Assistant becomes unresponsive with 1.37.1-1 installed. Right after a restart, HA becomes unusable. With z2mqtt disabled, all is fine.

Addon version

1.37.1-1

Platform

Core
2024.5.2
Supervisor
2024.05.1
Operating System
12.3
Frontend
20240501.1

Logs of the issue (if applicable)

No response

@Haverer
Copy link

Haverer commented May 10, 2024

Getting exactly the same here... anyway to select an older, working version?? I just get 'Loading Data' when trying to access Home Assistant now.

@Mayerox
Copy link

Mayerox commented May 10, 2024

I have some issues. After updating my RPi 3B, it went to reboot, then I started z2m. In the logs, z2m has no information because the RP froze and rebooted after. The core logs are attached, as is a screenshot of the RP.
home-assistant_2024-05-10T21-06-49.931Z.log
WhatsApp Image 2024-05-10 at 20 32 49 (1)

@Haverer
Copy link

Haverer commented May 10, 2024

I resolved mine by removing the login details for the MQTT broker.... it just used the default one I had installed.

@Mayerox
Copy link

Mayerox commented May 11, 2024

Я решил свою проблему, удалив данные для входа в брокер MQTT .... он просто использовал тот, который я установил по умолчанию.

Unfortunately this didn't help (

@sh0nuff
Copy link

sh0nuff commented May 15, 2024

I don't think this is an issue with Z2MQTT - I had no issues with the latest build until I updated my core from 4.4 to 5.2.

Upon updating the core, my baremetal HA hass.io device didn't reboot on it's own, and, after a hard reset, it booted, but when I try to start up Z2MQTT, I get this error:

Zigbee2MQTT Failed to get add-on logs, Unable to connect to systemd-journal-gatewayd

Which I've seen mentioned as part of recent Supervisor errors here. I was able to fix the issue by rolling back to a 4.4 Core backup file, but again I needed to hard restart my HA box.

@baiandin
Copy link

I confirm, same problem.
I'm not sure if this is because of zigbee2mqtt, but after launching the add-on, the Raspberry Pi actually began to freeze. No useful logs.
Hardware: Raspberry Pi 3 Model B+, Sonoff ZBDongle-E.

I tried:

  • perform a completely clean installation of HASS OS without restoring a backup;
  • restore backups with earlier versions of zigbee2mqtt and HA where everything worked before;
  • change HASS OS to Raspberry Pi OS Lite;
  • change Sonoff ZBDongle-E firmware;
  • change Raspberry Pi.
    No result.

Strange facts:

  • if you start the Raspberry Pi and insert ZBDongle-E after loading, then zigbee2mqtt starts;
  • if you install ZHA, it works fine.

@Stas505
Copy link

Stas505 commented May 23, 2024

Hi @baiandin, I have the same problem, did you find a solution?
I have already tried all the ways and have no ideas
And I'm the same way, if I start the raspberry pi and insert CC2331 after loading, then zigbee2mqtt starts normally.

@sedax90
Copy link

sedax90 commented May 23, 2024

I've the same problem and so far I haven't found any solution

@Stas505
Copy link

Stas505 commented May 23, 2024

Do you have any ideas on how to solve this?
I have only one idea, that the problem may be related to the connection of the adapter to the Raspberry Pi.
🤔

@tizio04
Copy link

tizio04 commented May 24, 2024

Same problem here: RPi 3B with ZBDongle-E, with both stable and edge version of ZB2MQTT, only a couple of second after the addon starts, the entire sistem crashes and restart; logs are no useful.
For now I migrated to ZHA (luckily I don't have many devices, so repairing them is not a huge problem), hoping this will be fixed

@lassikos
Copy link

Same issues. Cannot update HA to 5.x as it will not startup anymore. Running HA OS in a proxmox VM.

@NicolaP8
Copy link

Same here.
RPi 3B, Sonoff Dongle USB 3.0 V2 (E) with ncp-uart-hw-v7.4.2.0-zbdonglee-115200 fw.
HA 2024.5.5, Zigbee2MQTT 1.37.1-1

The system was used for some months with ZHA (now disabled) and original firmware. After installing Z2M and changing the firmware started the problems.

@gitaday
Copy link

gitaday commented Jun 6, 2024

Same issue here with:
Rpi3b+ 64bit
Installation Type Home Assistant OS
Operating System Version 6.6.28-haos-raspi
Operating System 12.3
Core 2024.6.0
Supervisor 2024.06.0
Agent Version 1.6.0
Docker Version 25.0.5
Frontend 20240605.0
Zigbee2mqtt: 1.38.0-1
Adapter: TI-CC2531

Issue details:
After the click on "start" of the zigbee2mqtt add-on, the whole OS crashes and it doesn't recover. No logs at all.

The following tentatives were unsuccessful:
a) move the adapter to another device and use ser2net
b) flash adapter firmware
c) reset adapter

The following options could be tried:
d) use a different adapter (but in my understanding the issue is not depending on a specific adapter)
e) use an active usb Hub to plug in the adapter
f) downgrade HA core to a version prior to 2024.4.5

The only working solution found so far was:

  1. disable Z2M addon
  2. install ZHA integration
  3. Thanks to @tizio04

@gitaday
Copy link

gitaday commented Jun 11, 2024

It might be a kernel/pi issue: (?)

Koenkk/zigbee2mqtt#22881

@sh0nuff
Copy link

sh0nuff commented Jun 13, 2024

It might be a kernel/pi issue: (?)

Koenkk/zigbee2mqtt#22881

I have the issue and I'm not on a Pi

@sedax90
Copy link

sedax90 commented Jun 13, 2024

I've switched from 2 weeks to zha and I've solved all problems. No stucks, lowest cpu usage, lowest temperatures, fastest responding.

@ldx00
Copy link

ldx00 commented Jul 3, 2024

I have the same issue on Virtual Box on Windows, all latest versions of everything. I posted here but here on the HA forums but here are the contents of my post anyway
https://community.home-assistant.io/t/haos-crashing-when-stopping-zha-or-zigbee2mqtt/743551/6?u=lxy00
I've written that 1.37 might have been OK but maybe that's where it started. Basically, trying to stop Z2M crashes the whole HAOS... Any help appreciated, post below.

#####################
I’m afraid I can’t help, as I’ve got exactly the same issue! The recent update to 1.39.0-1 obviously needs to stop the addon and then update it. I tried to update and it just crashed my whole HAOS (which also runs in a VirtualBox container coincidentally…) I am almost certain this did not happen in the past (specifically I think 1.37 was probably OK), so I’m very suspicious that some update, either to HAOS or Z2M is causing the issue.

For now I had to restart HAOS, catch it before it loaded the addons, do the update, then start the new version to get the update to install. I also did an uninstall and reinstall just in case something was messed up with the installation but when I click on stop, it still crashes my HAOS. Just confirmed it on the HAOS core update from today

Core 2024.7.0
Supervisor 2024.06.2
Operating System 12.4
Frontend 20240703.0

Would appreciate it if anyone has any updates! I’m not sure it matters but I have my sonoff stick on a USB 3 port and run it as a USB 2 port in the USB section of Virtual Box. I also after much tinkering managed to get Hyper-V completely disabled so it’s not that, although it took me ages to figure out how and it caused me no end of issues and crashes, which may have corrupted my installation somehow also, but when it’s running, everything seems to be OK!

@escobarin3
Copy link

I'm having the same issue... Virtualbox on Windows.. the Z2M addon keeps crashing my whole HAOS install... took a while to figure it out that it was an Z2M addon issue... When running the addon my CPU usage jumps to 70% to 80%... withouthe the addon the CPU is always below 8%. I have to stop and start the addon to get a low cpu usage... Any ideas to fix this?

@havardthom
Copy link

havardthom commented Jul 26, 2024

Same problem here, just found this after a day of debugging. My SD card went corrupt and I thought that was the culprit, so I reformatted and restored the SD card but it was still crashing every time I connected my Conbee 2 or started Z2M. I still thought it was problem with faulty SD card, so I switched to SSD setup with powered USB hub. Now I've setup the SSD with a total fresh HAOS and added everything manually, but it still crashes when I start Z2M (fresh install). Guess I'll have to disable Z2M for the time being.

Core 2024.7.3
Supervisor 2024.06.2
Operating System 12.4
Frontend 20240710.0

Zigbee2MQTT addon version 1.39.0-1

Raspberry Pi 3B+

Has anyone found a solution to this crashing?

Edit: Guess I'll setup ZHA as a temporary solution as others in this thread

@NicolaP8
Copy link

I simply use the old adapter driver: ezsp. Just ignore the (useless) warning!

@gaugit
Copy link

gaugit commented Aug 2, 2024

I'm seeing this issue as well on my virtual box installation of HAOS, as mentioned by others the issue is more to do with stopping the add-on than the the update itself. I tested this by just stopping the add-on without doing an update and HAOS still freezes.

Zigbee2MQTT version
1.38.0 commit: unknown
Coordinator type
EmberZNet
Coordinator revision
7.4.2 [GA]

Home Assistant
Core
2024.7.3
Supervisor
2024.06.2
Operating System
12.4
Frontend
20240710.0

@acormack
Copy link

acormack commented Aug 6, 2024

I also had a similar problem on my Virtual Box HAOS. I tried downgrading Core and OS and reflashing my SkyConnect dongle with different firmware - it madw no difference.

In the end I fixed it by changing the Virtual Box USB settings on the server to be USB 3, this seems to have cured it! I don't know why this was necessary, and it had worked quite happily without being USB 3 until a week ago.

But anyway, just in case this helps others I thought I would post here.

Alec

@SimonCtl
Copy link

SimonCtl commented Aug 7, 2024

Hi, has anyone managed to find a solution?
Home Assistant starts fine without Z2M. As soon as I manually start Z2M, it restarts HA.

@RetroDiesel
Copy link

RetroDiesel commented Aug 9, 2024

Having the same issue with HA running on VirtualBox. If I start the zigbee2mqtt add on or try to stop it, my VB freezes and can't even turn it off via the VirtualBox Manager.

It has been running ok but today I upgraded VirtualBox to the latest 7.0.20 and my problems started (was on 7.0.10).

Zigbee2mqtt version 1.39.1-1

Core 2024.8.0
Supervisor 2024.08.0
Operating System 12.4
Frontend 20240806.1

@paolo-tasca
Copy link

Hi,

I've experienced the same issue: after a month with ZHA and original firmware I decide to move to Zigbee2mqtt.
At the beginning with the original sonoff firmware but due the continuous crashes, I installed cp-uart-hw-v7.4.2.0-zbdonglee-115200 firmware with this configuration:

data_path: /config/zigbee2mqtt socat: enabled: false master: pty,raw,echo=0,link=/tmp/ttyZ2M,mode=777 slave: tcp-listen:8485,keepalive,nodelay,reuseaddr,keepidle=1,keepintvl=1,keepcnt=5 options: "-d -d" log: false mqtt: base_topic: zigbee2mqtt server: mqtt://homeassistant user: *** password: *** serial: port: /dev/serial/by-id/usb-ITEAD_SONOFF_Zigbee_3.0_USB_Dongle_Plus_V2_20240420152229-if00 adapter: ember

It works for 2 hours an then HAOS start to crash

Addon version
Zigbee2mqtt version 1.39.1-1

Platform
Core
2024.8.1
Supervisor
2024.08.0
Operating System
13.0 (I've also installed the new version)
Frontend
20240809.0

hardware
Raspberry Pi 3B+
Sonoff Dongle USB 3.0 V2 (E) with ncp-uart-hw-v7.4.2.0-zbdonglee-115200 fw

@nossSpb
Copy link

nossSpb commented Aug 21, 2024

I had the exact same issue. Rpi3B, ZBdongleE.
I rolled back to the 4.4 ocore version and everything is working now:
ha core update --version 2024.4.4

@paolo-tasca
Copy link

I had the exact same issue. Rpi3B, ZBdongleE. I rolled back to the 4.4 ocore version and everything is working now: ha core update --version 2024.4.4

This solution doesn't works for me, same issue

@NicolaP8
Copy link

A question to all people that has the problem: which driver are you using?
If it's "ember", have you tryed to use the old "ezsp"?

@RetroDiesel
Copy link

I had the exact same issue. Rpi3B, ZBdongleE. I rolled back to the 4.4 ocore version and everything is working now: ha core update --version 2024.4.4

This solution doesn't works for me, same issue

Same for me. Rolled back, still freezing.

@RetroDiesel
Copy link

RetroDiesel commented Aug 24, 2024

A question to all people that has the problem: which driver are you using? If it's "ember", have you tryed to use the old "ezsp"?

It was the opposite way around for me. I was on the old EZSP adapter with 7.2.2 firmware but your post got me thinking.

So I upgraded to Firmware 7.4.2 with ember and now my Zigbee2mqtt problems seem to have gone away. It's been over 12 hours now and no crashes (was 30 minutes before). The add on was noticeably faster on start up too.

EDIT: HA has now been running for nearly 5 days straight with no crashes which is unheard of for my set up for the last year where the best was 3 days.

@evelant
Copy link

evelant commented Aug 29, 2024

I'm using a zbdongle-p, so zstack, not ezsp or ember, and I'm running into this. Just re-paired my whole network from zha to z2m. Everything worked fine for most of the day. All of a sudden the hass UI will no longer load. That definitely seems to point to the z2m addon or z2m itself as the culprit, not the driver for the stick.

@SimonCtl
Copy link

Quick update for me, I have decided to upgrade my RPi3B+ to a mini-PC (N100,8gb ram, 512gb ssd) and problem is over.

@evelant
Copy link

evelant commented Aug 29, 2024

I'm on a pi5 8gb so I should have plenty of headroom for z2m... Given that this never happened before I switched to z2m it seems like there's a bug somewhere.

@evelant
Copy link

evelant commented Aug 29, 2024

It seems like it unblocked itself after a lot of waiting. I was able to check the z2m addon page and the hardware page -- only 4gb ram in use out of 8gb and cpu hovering around 8% load so it's not something bogging down the system via load. The issue came back shortly after. Seems like something is blocking the webserver?

@JesperKuipers
Copy link

@evelant Got the same issue, but for me it is also freezing my RPI and throwing it almost in a bootloop (when starting on start up is enabled), meanwhile there is nothing in the logs to diagnose it.

@paolo-tasca
Copy link

A question to all people that has the problem: which driver are you using? If it's "ember", have you tryed to use the old "ezsp"?

I did some tests with a new clear installation only with mosquito e Zigbee2MQTT add-on, with a new SD card, in two way:
version 2024.4.4 and version 2024.9.0 both tested with adapter: ember and adapter: ezsp parameter.

The result are the same: when I click start on Zigbee2MQTT, after some second the system became unresponsible and this is a screenshot of the RP same second before restart. The first line of log appeared on starting Zigbee2MQTT plugin
home-assistant_2024-05-10T21-06-49.931Z.log
image

@gaugit
Copy link

gaugit commented Sep 6, 2024

I'm using the ezsp driver, I'm gonna try to revert to z2m version beforr 1.37 and see it can be stopped without HA getting stuck

@gaugit
Copy link

gaugit commented Sep 7, 2024

I reverted far back to 1.35, and the issue is still present. intrestingly I had no issues with an older version of home assistant when I had updated from 1.35 to 1.36 in the past. I think this bug needs to be posted on HA's plate.
The only way to currently update Z2M is to:

  • Turn off "start on boot" for Z2m
  • reboot home assistant
  • update the add on in turn of state.

@atiffarrukh
Copy link

atiffarrukh commented Sep 8, 2024

I was having the same issue. Adding frontend: true had helped here. It should be added in the configuration by clicking "Edit in YAML" and on top/bottom of file and making sure that hostname in configuration is core-mosquitto

@semik
Copy link

semik commented Sep 17, 2024

I've same issue here.

My HomeAssistant is running inside virtualbox virtual. I was unable to upgrade from 1.39.0-1, any time i tried upgrade it immediately hung. So I tried to turnoff, reboot, update and now I'm unable to start AddOn. It says in logs:

exec /sbin/tini: exec format error
exec /sbin/tini: exec format error
exec /sbin/tini: exec format error
exec /sbin/tini: exec format error
exec /sbin/tini: exec format error

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests