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

Update to 1.42.0, Now zigbee-herdsman cannot find Sonoff dongle. #25007

Closed
evanheckert opened this issue Dec 2, 2024 · 24 comments
Closed

Update to 1.42.0, Now zigbee-herdsman cannot find Sonoff dongle. #25007

evanheckert opened this issue Dec 2, 2024 · 24 comments
Labels
problem Something isn't working

Comments

@evanheckert
Copy link

What happened?

Everything was working perfectly. When the update to 1.42.0 completed, starting Zigbee2MQTT addon now fails, results in:

[00:32:44] INFO: Preparing to start...
[00:32:44] INFO: Socat not enabled
[00:32:44] INFO: Starting Zigbee2MQTT...
Starting Zigbee2MQTT without watchdog.
[2024-12-02 00:32:46] info: 	z2m: Logging to console, file (filename: log.log)
[2024-12-02 00:32:46] info: 	z2m: Starting Zigbee2MQTT version 1.42.0 (commit #unknown)
[2024-12-02 00:32:46] info: 	z2m: Starting zigbee-herdsman (2.1.9)
[2024-12-02 00:32:46] error: 	z2m: Error while starting zigbee-herdsman
[2024-12-02 00:32:46] error: 	z2m: Failed to start zigbee
[2024-12-02 00:32:46] error: 	z2m: Check https://www.zigbee2mqtt.io/guide/installation/20_zigbee2mqtt-fails-to-start.html for possible solutions
[2024-12-02 00:32:46] error: 	z2m: Exiting...
[2024-12-02 00:32:46] error: 	z2m: Error: No path provided and failed to auto detect path
    at Function.create (/app/node_modules/zigbee-herdsman/src/adapter/adapter.ts:107:23)
    at processTicksAndRejections (node:internal/process/task_queues:95:5)
    at Controller.start (/app/node_modules/zigbee-herdsman/src/controller/controller.ts:133:24)
    at Zigbee.start (/app/lib/zigbee.ts:69:27)
    at Controller.start (/app/lib/controller.ts:161:27)
    at start (/app/index.js:154:5)

The device still shows up as expected:

➜  /config ls -l /dev/serial/by-id/
total 0
lrwxrwxrwx 1 root root 13 Dec  2 00:20 usb-ITead_Sonoff_Zigbee_3.0_USB_Dongle_Plus_f60cdffb9219ec11b24937cc47486eb0-if00-port0 -> ../../ttyUSB0
lrwxrwxrwx 1 root root 13 Dec  2 00:20 usb-Silicon_Labs_Zooz_ZST10_700_Z-Wave_Stick_7676b97b3d67ec11a5eaa07089640db2-if00-port0 -> ../../ttyUSB1
➜  /config test -w /dev/serial/by-id/usb-ITead_Sonoff_Zigbee_3.0_USB_Dongle_Plus_f60cdffb9219ec11b24937cc47486eb0-if00-port0 && echo success || echo failure
success

Restarting home assistant and restarting the host machine still result in the same error message on startup attempt.

What did you expect to happen?

I expected that it would continue functioning normally as it did prior to the update.

How to reproduce it (minimal and precise)

Not sure, but my configuration.yaml:

homeassistant: true
mqtt:
  server: mqtt://core-mosquitto:1883
  user: addons
  password: Ufui7cee1oozoh4Eif7ceoXeeWoo9Zoo1eeJai3ion0bahTohvaChangiw7awohl
serial:
  port: /dev/serial/by-id/usb-ITead_Sonoff_Zigbee_3.0_USB_Dongle_Plus_f60cdffb9219ec11b24937cc47486eb0-if00-port0
frontend:
  port: 8099
advanced:
  homeassistant_legacy_entity_attributes: false
  legacy_api: false
  legacy_availability_payload: false
device_options:
  legacy: false
devices:
  '0xccccccfffee5f52a':
    friendly_name: Black Floor Lamp
  '0xccccccfffee69bbf':
    friendly_name: Living Room Fan Bulb 1
  '0xec1bbdfffe3d7017':
    friendly_name: Living Room Fan Bulb 2
  '0xec1bbdfffe8a72c8':
    friendly_name: Nursery Fan Bulb 1
  '0xccccccfffef19c9a':
    friendly_name: Nursery Fan Bulb 2
  '0xec1bbdfffe2e2649':
    friendly_name: Nursery Old Floor Lamp
  '0xccccccfffee6890c':
    friendly_name: Nursery Globe Lamp
  '0xccccccfffeea8cd0':
    friendly_name: Living Room Silver Floor Lamp
  '0xec1bbdfffe37d29e':
    friendly_name: Living Room Antique Floor Lamp
  '0xccccccfffee3f6d7':
    friendly_name: Entry Light Bulb 1
  '0xccccccfffee12a15':
    friendly_name: Entry Light Bulb 3
  '0xccccccfffeebbdb2':
    friendly_name: Entry Light Bulb 2
  '0xccccccfffee5e0f4':
    friendly_name: Entry Sconce
  '0x00158d0006bcdb05':
    friendly_name: Nursery Weather
  '0x00124b001f6a1236':
    friendly_name: Living Room TV Backlight Dimmer
  '0xccccccfffee13098':
    friendly_name: Bedroom Lamp
  '0xec1bbdfffe2f48e1':
    friendly_name: Twins Room Fan Bulb 1
  '0xec1bbdfffe3dadf7':
    friendly_name: Twins Room Fan Bulb 2
  '0x000d6ffffea4697d':
    friendly_name: Outlet 3 Maser Bedroom Noise Machine
  '0x00158d00056a1cf0':
    friendly_name: Bedroom Weather
  '0xccccccfffe94b779':
    friendly_name: Twins Room Bathroom Bulb 1
  '0xec1bbdfffe2e293f':
    friendly_name: Twins Room Bathroom Bulb 2
  '0xccccccfffeedb89f':
    friendly_name: Twins Room Bathroom Bulb 3
  '0x00158d0007ed7649':
    friendly_name: Freezer Weather
  '0x000d6ffffe263971':
    friendly_name: Outlet 4 Office Mini-Sun
  '0x000d6ffffea4dafc':
    friendly_name: Outlet 1 Freezer
  '0x00158d0006bcabba':
    friendly_name: Basement Weather
  '0x04cd15fffe1ffc2d':
    friendly_name: Nursery Blinds
  '0xccccccfffe2d5b98':
    friendly_name: Twins Room Floor Lamp Bulb
  '0xcc86ecfffeb79981':
    friendly_name: Twins Room Ceiling Dimmer

Zigbee2MQTT version

1.24.0

Adapter firmware version

cannot access

Adapter

ITead_Sonoff_Zigbee_3.0_USB_Dongle_Plus

Setup

Home Assistant as a VM on a Proxmox box on X86-64 Thinkpad

Debug log

[00:32:44] INFO: Preparing to start...
[00:32:44] INFO: Socat not enabled
[00:32:44] INFO: Starting Zigbee2MQTT...
Starting Zigbee2MQTT without watchdog.
[2024-12-02 00:32:46] info: 	z2m: Logging to console, file (filename: log.log)
[2024-12-02 00:32:46] info: 	z2m: Starting Zigbee2MQTT version 1.42.0 (commit #unknown)
[2024-12-02 00:32:46] info: 	z2m: Starting zigbee-herdsman (2.1.9)
[2024-12-02 00:32:46] error: 	z2m: Error while starting zigbee-herdsman
[2024-12-02 00:32:46] error: 	z2m: Failed to start zigbee
[2024-12-02 00:32:46] error: 	z2m: Check https://www.zigbee2mqtt.io/guide/installation/20_zigbee2mqtt-fails-to-start.html for possible solutions
[2024-12-02 00:32:46] error: 	z2m: Exiting...
[2024-12-02 00:32:46] error: 	z2m: Error: No path provided and failed to auto detect path
    at Function.create (/app/node_modules/zigbee-herdsman/src/adapter/adapter.ts:107:23)
    at processTicksAndRejections (node:internal/process/task_queues:95:5)
    at Controller.start (/app/node_modules/zigbee-herdsman/src/controller/controller.ts:133:24)
    at Zigbee.start (/app/lib/zigbee.ts:69:27)
    at Controller.start (/app/lib/controller.ts:161:27)
    at start (/app/index.js:154:5)
@evanheckert evanheckert added the problem Something isn't working label Dec 2, 2024
@jocel1
Copy link

jocel1 commented Dec 2, 2024

same issue here, zigbee2MQTT doesn't restart with the same error
I double checked and the port is ok, and tried adding the adapter option without more success

homeassistant: true
permit_join: false
mqtt:
  base_topic: zigbee2mqtt
  server: mqtt://core-mosquitto:1883
  keepalive: 60
  reject_unauthorized: true
  version: 4
  user: addons
  password: xxxx
serial:
  port: /dev/serial/by-id/usb-ITead_Sonoff_Zigbee_3.0_USB_Dongle_Plus_e628cce69145ec119adc94fd6f14af06-if00-port0
  adapter: zstack
frontend:
  port: 8099
devices:
  '0x001788010bcf4a6c':
    friendly_name: Détecteur mouvement Joce
  '0x001788010b7b2ab5':
    friendly_name: Gestions volets
  '0x001788010bcf1916':
    friendly_name: Detecteur mouvement sdb haut
  '0x001788010bce7105':
    friendly_name: Détecteur mouvement couloir
  '0x0015bc002f0118ab':
    friendly_name: Prise Meuble TV
  '0x001788010896cce2':
    friendly_name: Interrupteur bureau Joce
    legacy: false
  '0x001788010896ca50':
    friendly_name: Interrupteur lampe Elina
    legacy: false
  '0x00124b0024c27bdf':
    friendly_name: Prise salon
  '0x0015bc002f00cc03':
    friendly_name: Prise salle de bain
  '0x00124b0024c27c66':
    friendly_name: 'Prise salle à manger (fer à repasser) '
  '0x0015bc002f0119c9':
    friendly_name: Prise salle à manger (robot)
  '0x0015bc002f00cecc':
    friendly_name: Prise salle à manger (meuble)
  '0x0015bc002f01181a':
    friendly_name: Prise local électrique
  '0x0015bc002f011841':
    friendly_name: Prise frigo
  '0x0015bc002f00cc4d':
    friendly_name: Prise buanderie seche linge
  '0xa4c138480c19f813':
    friendly_name: Prise bureau écran / HP
  '0xa4c138913678561b':
    friendly_name: Prise caisson de basses
  '0xa4c138da7440221b':
    friendly_name: Prise dock belkin
  '0xa4c138314c66ec6f':
    friendly_name: Prise lampe Elina
  '0xa4c138175450aa7d':
    friendly_name: Prise routeur wifi mac
  '0xa4c1380d63e3647c':
    friendly_name: Prise chambre Elina
  '0xa4c13805d7e57c4e':
    friendly_name: Prise HP Lia
  '0x0015bc002f011716':
    friendly_name: Prise bureau lia
  '0x001788010cdadad6':
    friendly_name: Détecteur mouvement salle à manger
  '0xa4c1381b79fc3a2b':
    friendly_name: Prise bureau Joce
  '0xa4c138af288cc205':
    friendly_name: Prise meuble blanc
  '0xa4c138b0f44f7248':
    friendly_name: Prise entrée
  '0xa4c138be50d21a91':
    friendly_name: Prise chambre parents
  '0x0015bc002f0119c2':
    friendly_name: Prise cave
  '0x0015bc002f00ccf5':
    friendly_name: Prise ampli TV
  '0x0015bc002f00cc70':
    friendly_name: Prise micro-onde
  '0x0015bc002f0116b5':
    friendly_name: Prise cuisine (porte fenêtre)
  '0x001788010b416e66':
    friendly_name: Lampe bureau Joce
  '0xa4c1383d5fd8311d':
    friendly_name: Prise imprimante Lia
  '0x00124b0025037fe7':
    friendly_name: Capteur humidité local electrique
  '0x00124b002503843e':
    friendly_name: Capteur humidité salle de bain
  '0x001788010df8ee01':
    friendly_name: Detecteur mouvement Elina
advanced:
  homeassistant_legacy_entity_attributes: false
  homeassistant_legacy_triggers: false
  legacy_api: false
  legacy_availability_payload: false
  transmit_power: 10
device_options:
  legacy: false  
groups: {}
ota:
  ikea_ota_use_test_url: false
  disable_automatic_update_check: true

@will0913
Copy link

will0913 commented Dec 2, 2024

I got it to work after moving the configuration folder under the new addon_configs folder.

/homeasssistant/zigbee2mqtt => /root/addon_configs/[randomstring]_zigbee2mqtt/zigbee2mqtt
^^^^^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
old       =>           new configuration location

@jocel1
Copy link

jocel1 commented Dec 2, 2024

ok got it, have to move the zigbee configuration file in addon_config to make it work properly

@jocel1
Copy link

jocel1 commented Dec 2, 2024

Note I read the migration step, but since the example is for supervisor and there were no addon_configs directory in the homeassistant directory, I didn't check with the terminal in the rootdir and incorrectly assumed it was only for supervisor installation.

@jocel1
Copy link

jocel1 commented Dec 2, 2024

@will0913 have you also lost almost all the device associations?

@will0913
Copy link

will0913 commented Dec 2, 2024

@jocel1 , No, I still have all my devices.
I moved the config directory to the new location via terminal add on.

p.s. I have the homeassistant OS vm

@jocel1
Copy link

jocel1 commented Dec 2, 2024

Thanks! I think I understand why, it's because I disabled as well with the migration the legacy api

@espe20
Copy link

espe20 commented Dec 2, 2024

same issue, I made the steps that You mentioned but still the same error return on addon startup. I think this is realted to that point:
image
Have You mount this path? Can You describe me how to do it?

@evanheckert
Copy link
Author

evanheckert commented Dec 2, 2024

Moving the folder as described didn't change anything, even after a full home assistant restart. Found the destination folder and ran:
mv /config/zigbee2mqtt /root/addon_configs/45df7312_zigbee2mqtt/zigbee2mqtt

EDIT: That moved it into zigbee2mqtt/zigbee2mqtt, so I corrected that and it did start sucessfully, but everything is showing "Entity not found".

@will0913
Copy link

will0913 commented Dec 2, 2024

contents of my zigbee2mqtt folder:
configuration.yaml
coordinator_backup.json
database.db
log/
state.json

Could it result from missing database.db?

@espe20
Copy link

espe20 commented Dec 2, 2024

Moving the folder as described didn't change anything, even after a full home assistant restart. Found the destination folder and ran: mv /config/zigbee2mqtt /root/addon_configs/45df7312_zigbee2mqtt/zigbee2mqtt

EDIT: That moved it into zigbee2mqtt/zigbee2mqtt, so I corrected that and it did start sucessfully, but everything is showing "Entity not found".

it is not work, still the same error:
[11:31:27] INFO: Preparing to start... [11:31:27] INFO: Socat not enabled [11:31:27] INFO: Starting Zigbee2MQTT... Starting Zigbee2MQTT without watchdog. [2024-12-02 11:31:29] info: z2m: Logging to console, file (filename: log.log) [2024-12-02 11:31:29] info: z2m: Starting Zigbee2MQTT version 1.42.0 (commit #unknown) [2024-12-02 11:31:29] info: z2m: Starting zigbee-herdsman (2.1.9) [2024-12-02 11:31:29] error: z2m: Error while starting zigbee-herdsman [2024-12-02 11:31:29] error: z2m: Failed to start zigbee [2024-12-02 11:31:29] error: z2m: Check https://www.zigbee2mqtt.io/guide/installation/20_zigbee2mqtt-fails-to-start.html for possible solutions [2024-12-02 11:31:29] error: z2m: Exiting... [2024-12-02 11:31:29] error: z2m: Error: No path provided and failed to auto detect path at Function.create (/app/node_modules/zigbee-herdsman/src/adapter/adapter.ts:107:23) at processTicksAndRejections (node:internal/process/task_queues:95:5) at Controller.start (/app/node_modules/zigbee-herdsman/src/controller/controller.ts:133:24) at Zigbee.start (/app/lib/zigbee.ts:69:27) at Controller.start (/app/lib/controller.ts:161:27) at start (/app/index.js:154:5)

@will0913
Copy link

will0913 commented Dec 2, 2024

@espe20 , Are you able to locate your zigbee2mqtt folder?
move its content to /addon_configs

Moving the folder as described didn't change anything, even after a full home assistant restart. Found the destination folder and ran: mv /config/zigbee2mqtt /root/addon_configs/45df7312_zigbee2mqtt/zigbee2mqtt
EDIT: That moved it into zigbee2mqtt/zigbee2mqtt, so I corrected that and it did start sucessfully, but everything is showing "Entity not found".

it is not work, still the same error: [11:31:27] INFO: Preparing to start... [11:31:27] INFO: Socat not enabled [11:31:27] INFO: Starting Zigbee2MQTT... Starting Zigbee2MQTT without watchdog. [2024-12-02 11:31:29] info: z2m: Logging to console, file (filename: log.log) [2024-12-02 11:31:29] info: z2m: Starting Zigbee2MQTT version 1.42.0 (commit #unknown) [2024-12-02 11:31:29] info: z2m: Starting zigbee-herdsman (2.1.9) [2024-12-02 11:31:29] error: z2m: Error while starting zigbee-herdsman [2024-12-02 11:31:29] error: z2m: Failed to start zigbee [2024-12-02 11:31:29] error: z2m: Check https://www.zigbee2mqtt.io/guide/installation/20_zigbee2mqtt-fails-to-start.html for possible solutions [2024-12-02 11:31:29] error: z2m: Exiting... [2024-12-02 11:31:29] error: z2m: Error: No path provided and failed to auto detect path at Function.create (/app/node_modules/zigbee-herdsman/src/adapter/adapter.ts:107:23) at processTicksAndRejections (node:internal/process/task_queues:95:5) at Controller.start (/app/node_modules/zigbee-herdsman/src/controller/controller.ts:133:24) at Zigbee.start (/app/lib/zigbee.ts:69:27) at Controller.start (/app/lib/controller.ts:161:27) at start (/app/index.js:154:5)

@espe20
Copy link

espe20 commented Dec 2, 2024

Yes I am able and I found it also move it to location and still without luck. Is HA restart needed?

@espe20
Copy link

espe20 commented Dec 2, 2024

I made a restore backup and lost all config :(
So now I clean up everything and remove addon.
After that I want to make clean install of addon and can't start it at all:
[12:34:16] INFO: Preparing to start...
[12:34:16] INFO: Socat not enabled
[12:34:16] INFO: Starting Zigbee2MQTT...
Starting Zigbee2MQTT without watchdog.
[2024-12-02 12:34:18] info: z2m: Logging to console, file (filename: log.log)
[2024-12-02 12:34:18] info: z2m: Starting Zigbee2MQTT version 1.42.0 (commit #unknown)
[2024-12-02 12:34:18] info: z2m: Starting zigbee-herdsman (2.1.9)
[2024-12-02 12:34:18] error: zh:zstack:znp: Failed to determine if path is valid: 'Error: ENOENT: no such file or directory, lstat '/app/dev''
[2024-12-02 12:34:18] info: zh:zstack:znp: Opening SerialPort with {"path":"dev/ttyUSB0","baudRate":115200,"rtscts":false,"autoOpen":false}
[2024-12-02 12:34:18] error: z2m: Error while starting zigbee-herdsman
[2024-12-02 12:34:18] error: z2m: Failed to start zigbee
[2024-12-02 12:34:18] error: z2m: Check https://www.zigbee2mqtt.io/guide/installation/20_zigbee2mqtt-fails-to-start.html for possible solutions
[2024-12-02 12:34:18] error: z2m: Exiting...
[2024-12-02 12:34:18] error: z2m: Error: Error: No such file or directory, cannot open dev/ttyUSB0

I see addon create a config when expected by release info

@dverboom
Copy link

dverboom commented Dec 2, 2024

Same issue here with "Home Assistant Operating System", however, with a "slae.sh_cc2652rb_stick"
configuration was moved during update from "/config/zigbee2mqtt" to "/addon_config/zigbee2mqtt"

Starting Zigbee2MQTT without watchdog.
[2024-12-02 12:35:43] info: z2m: Logging to console, file (filename: log.log)
[2024-12-02 12:35:43] info: z2m: Starting Zigbee2MQTT version 1.42.0 (commit #unknown)
[2024-12-02 12:35:43] info: z2m: Starting zigbee-herdsman (2.1.9)
[2024-12-02 12:35:43] error: z2m: Error while starting zigbee-herdsman
[2024-12-02 12:35:43] error: z2m: Failed to start zigbee
[2024-12-02 12:35:43] error: z2m: Check https://www.zigbee2mqtt.io/guide/installation/20_zigbee2mqtt-fails-to-start.html for possible solutions
[2024-12-02 12:35:43] error: z2m: Exiting...
[2024-12-02 12:35:43] error: z2m: Error: No path provided and failed to auto detect path
at Function.create (/app/node_modules/zigbee-herdsman/src/adapter/adapter.ts:107:23)
at processTicksAndRejections (node:internal/process/task_queues:95:5)
at Controller.start (/app/node_modules/zigbee-herdsman/src/controller/controller.ts:133:24)
at Zigbee.start (/app/lib/zigbee.ts:69:27)
at Controller.start (/app/lib/controller.ts:161:27)
at start (/app/index.js:154:5)

@PatrickHuetter
Copy link

I had the same issue after updating. Moving a copy (full overwrite) from the old directory to the new one worked. Be sure to stop zigbee2mqtt before doing the process.

cp -R /homeassistant/zigbee2mqtt/* /root/addon_configs/<some-hash>_zigbee2mqtt/zigbee2mqtt/

After that you can delete/cleanup the old directory. I'll do it a few days later.

@espe20
Copy link

espe20 commented Dec 2, 2024

funny thing is... after upgrade and every uninstall and install again this addon with newest 1.42 ver get the same like before and exactly the same like in release notes:
image
so I think it is static

@espe20
Copy link

espe20 commented Dec 2, 2024

also on my HAOS after clean install of new addon with ver 1.42 can't start it again with errors in previous comments.

I downgraded to 1.41 and fetch backup of z2m from HA backup file and then it runns again with old config but can't run ui because of 503: Service Unavailable

EDIT:
After a long while it start by self

@Davyr55
Copy link

Davyr55 commented Dec 2, 2024

I had the same problem, just downgraded to 1.40.2-1
Go to settings - system - backups
It showed the automatic backup before I upgraded, just click on it and hit restore.
Everything worked fine after that

@majkers
Copy link

majkers commented Dec 2, 2024

Strange thing. I don't have zigbee2mqtt in config folder but in share folder... I still did not update to latest z2m version because of this mess but I wonder what would happen in my case...

@evanheckert
Copy link
Author

When I reverted to 1.40.2 it deleted the new folder that I copied over. I restored from a backup, but apparently the backup doesn't backup the database because all of my 40+ devices are still gone.

@ykw11n
Copy link

ykw11n commented Dec 2, 2024

I did the update yesterday and lost all devices as well.
I tried to move the config folder but all devices were still gone so I went back to 1.41 hoping we'll have more informations about what to do exactly when upgrading. When you update it makes a backup by default so you can do like me and restore previous save.

@Nerivec
Copy link
Collaborator

Nerivec commented Dec 2, 2024

Please see zigbee2mqtt/hassio-zigbee2mqtt#664 (comment)
Closing this one to avoid too much spread-out information.

@Nerivec Nerivec closed this as completed Dec 2, 2024
@kyrgorsh
Copy link

kyrgorsh commented Dec 2, 2024

I had troubles starting plug-in because of data_path setting of ver 1.42.0-1 after new installation. Once upgraded to 1.42.0-2 data_path issue was solved but plugin was still crushing during start becasue of firmware and deprecated ezsp drivers. I have upgraded firmware of my Sonoff dongle E to the latest version and finally started the plugin using ember drivers. Added several devises.

They were gone ! after restart. default data_path option still points to config/zigbee2mqtt .

What is finally right place and correct settings ?

Repository owner locked as resolved and limited conversation to collaborators Dec 3, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
problem Something isn't working
Projects
None yet
Development

No branches or pull requests