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

Upgrading to 1.42.0-1 removes all the devices #664

Closed
Igloczek opened this issue Dec 2, 2024 · 103 comments
Closed

Upgrading to 1.42.0-1 removes all the devices #664

Igloczek opened this issue Dec 2, 2024 · 103 comments

Comments

@Igloczek
Copy link

Igloczek commented Dec 2, 2024

Description of the issue

Upgrading the add-on from v1.41.0-1 to 1.42.0-1 removes all the configured devices and possibly other config options, I didn't check it, just run to restore backup ASAP.

Since this is not a major release, it shouldn't introduce any breaking changes.

Addon version

1.42.0-1

Platform

Core 2024.11.3
Supervisor 2024.11.4
Operating System 13.2
Frontend 20241106.2

Logs of the issue (if applicable)

No response

@Igloczek
Copy link
Author

Igloczek commented Dec 2, 2024

Also this is weird, it shows some other release notes than the one you have on Github 🤔

It kinda looks like the add-on was upgraded using code from the master branch, instead of the tagged version, so we get some WIP stuff there.

CleanShot 2024-12-02 at 13 53 15

@Acey-yo
Copy link

Acey-yo commented Dec 2, 2024

Same here....-_-

@Igloczek
Copy link
Author

Igloczek commented Dec 2, 2024

That's interesting, in my case restoring backup did a trick 🤔

@AppleFlapp
Copy link

My add-on is not even starting. Error while starting zigbee-herdsman

@supermarkert
Copy link

supermarkert commented Dec 2, 2024

Also this is weird, it shows some other release notes than the one you have on Github 🤔

It kinda looks like the add-on was upgraded using code from the master branch, instead of the tagged version, so we get some WIP stuff there.

I had the same question. I had no issues upgrading, but noticed that my config was not actually migrated as indicated in the "unreleased" notes. I think those notes are intended for the upcoming 2.0 release in January, and don't apply to this release.

@Kopetan4egX
Copy link

All devices removed, restoring backup doesn't help at all

@samumar82
Copy link

Same issue here, tried to followup the steps to move the directory but the path is different using the Home Assistant Green devices. All zigbee devices are not responding anymore although I can see all there in the Z2M list

@CodyJon
Copy link

CodyJon commented Dec 2, 2024

Same issues.. .oooof tried all the above still cannot control any Z2M devices..

@Kopetan4egX
Copy link

All zigbee devices are not responding anymore although I can see all there in the Z2M list

Check their names in HA, not in Z2M list. I've already read reports about entities been renamed to their friendly names. Happened to me too. Instead of default IEEE (or whatever it is) name i have something like water_heater_plug. Need to somehow rename them all back... I hope there is another way to fix this, not manually.

@JaCoLJcL
Copy link

JaCoLJcL commented Dec 2, 2024

After reset whole system (red button) and backup zigbee2mqtt start

@MTokarev
Copy link

MTokarev commented Dec 2, 2024

After I updated the system, all my devices disappeared.
Not sure if that will help other, but I left a comment in this topic: Koenkk/zigbee2mqtt#25004 (comment)

@Koenkk
Copy link
Contributor

Koenkk commented Dec 2, 2024

Could you check if this is fixed in the 1.42.0-2 addon? Should be there in a few mins from now.

@GraemeF
Copy link

GraemeF commented Dec 2, 2024

Could you check if this is fixed in the 1.42.0-2 addon? Should be there in a few mins from now.

Looks like that has done the trick! Devices are back

@Damien2407
Copy link

Hi guys
I realized that after the update that in configuration.yaml for each device i had a line like this that was added:

This is for the icon....

Screenshot 2024-12-02 at 22-12-16 Studio Code Server – Home Assistant

@z-master42
Copy link

That was already there before.

@polygon242
Copy link

I had the problem with the huge config file containing device icon data a while back because i ticked the option "Bilder lokalisieren (locize pictures)" in the gui under config/tools. System was unusable so i restored old config file ..

@Pferdebockwurst
Copy link

Could you check if this is fixed in the 1.42.0-2 addon? Should be there in a few mins from now.

@Koenkk Thank you for the fix! But I was able to "fix" the error after upgrading to 1.42.0-1 on my own by simply following the advice and moving the config folder. Can I safely update to 1.42.0-2 anyway or would I have to move the folder back to the former location?

@Sholofly
Copy link

Sholofly commented Dec 2, 2024

Same here, raspberry pi haos instalation. Some devices working some not, reverse backup dont work. Fix it quick!

Fix it quick? It's a free integration, you don't have anything to demand here. It's open surce, if you want quick solutions please consider contributing to this repo.

@billiepreks
Copy link

billiepreks commented Dec 2, 2024

Just spend the day to reappair everything, fix all automations & co. Saw the update, felt stupid, updated z2m, then lost everything again

And revert back to save previous update don't restore my devices. Sad. Will see tommorrow aha

Still, thanks for your work @Koenkk , take the time you need

@zviratkos
Copy link

Hello,

have you seen comment about relocated root directory? I had same experience, but I then moved data from:
/usr/share/hassio/homeassistant/zigbee2mqtt/
to
/usr/share/hassio/addon_configs/45df7312_zigbee2mqtt/zigbee2mqtt/
and started plugin as usual, all data were there, everything is working fine.

BR JS

@Crocmagnon
Copy link

Just came here to mention that I didn’t observe any issue when upgrading to 1.42.0-1. I also upgraded to 1.42.0-2 and things are still running smoothly.

@Tamsy
Copy link

Tamsy commented Dec 3, 2024

I didn’t observe any issue when upgrading to 1.42.0-1. I also upgraded to 1.42.0-2 and things are still running smoothly.

The very same here on two instances here running HA Supervisor. No issues encountered so far.

@billiepreks
Copy link

Hello,

have you seen comment about relocated root directory? I had same experience, but I then moved data from: /usr/share/hassio/homeassistant/zigbee2mqtt/ to /usr/share/hassio/addon_configs/45df7312_zigbee2mqtt/zigbee2mqtt/ and started plugin as usual, all data were there, everything is working fine.

BR JS

The thing is when I updated to 0-1 I still had my devices. It was when I did the migration that I lost them all. I re-paired them all, then saw the 0-2 update, did a save then updated. Lost all devices again, and restoring save dont bring them back.

@axolotls666
Copy link

A lot of these minor updates breaks my system, so I just rollback and the next one usually works. Will try this one. Thanks.

@raphael1688
Copy link

raphael1688 commented Dec 3, 2024

I have the following 'lagecy' settings changed to false ever since version 1.31 or older. No issue upgraded from 1.41.0-1.

homeassistant:
legacy_triggers: false
mqtt:
base_topic: zigbee2mqtt_MAIN
server: mqtt://core-mosquitto
user:
password:
version: 5
serial:
port: tcp://192.168.88.96:6638
baudrate: 230400
adapter: ember
rtscts: false
frontend:
port: 8099
advanced:
homeassistant_legacy_entity_attributes: false
legacy_api: false
legacy_availability_payload: false
log_syslog:
app_name: Zigbee2MQTT
eol: /n
host: localhost
localhost: localhost
path: /dev/log
pid: process.pid
port: 514
protocol: udp4
type: '5424'
channel: 23
transmit_power: 20
adapter_delay: 0
log_level: warn
last_seen: ISO_8601
device_options:
legacy: false

@PsychoOW
Copy link

PsychoOW commented Dec 3, 2024

hello, first of all, thank you for that great project! its really a blessing :) i have a question please. may i ask if its safe to update? i was an idiot and didnt move folder so i had to re pair everything and now i am afraid to update because it says "an attempt to fix github issue 664", now i ask myself if i should update or better skip and update next update release. i am not so experienced so i am afraid to break something :(

@Pferdebockwurst
Copy link

Lucky i did NOT update at all..

I really don't know why this version has been released.. majority of the people don't even know what to do... so updating from a remote location is a no-no for me now. so i stay on 1.41.0-1 till everything works automatically...

Maybe take your time to think again and delete this comment. This definitely didn't happen intentionally. Remember, the developers made this great software during their free-time.

@ChristianHannover
Copy link

Same issues here.
The Zigbee2MQTT-config for SLZB 06 M have been updated (1.42.0-1) and running without any issues.
My Sonoff Bridge Pro where not starting at all. I updated Tasmota on the Sonoff Bridge Pro to 14.3.0.7 (coming from Tasmota 14.3.04) and were able to start the bridges under the updated firmware (and Zigbee2MQTT 1.42.0-1) - but without the former Zigbee2MQTT-configuration (which I copied and configured as described in the HA info section) - all devices are lost and obviously have to be repaired.
Also, the Sonoff Bridge Pro is not running stable a long time while dropping off the network regulary (which not happend before the update to Zigbee2MQTT vs. 1.42.0-1).
The Sonoff Bridge Pro first started after I switched from ember to eszp and back to ember in the options (I tried with the options as I was not sure where the connection issues have to be searched). A bit strange. I will try to switch the ZigBee channels for a more stable connection to avoid conflicts with wifi/zigbee from other devices/networks.

The Sonoff Bridge Pro (I am using two of them ) are connected via wifi.
The SLZM 06 M (I am using three of them) are connected via wifi (2x) and via eth0 (1x).

@dpgh947
Copy link

dpgh947 commented Dec 3, 2024

The only other problem i have is that checking for ota updates crashes the addon, no idea if thats related.

Checking for ota updates works ok for me too. Strange...

@johnthomas00
Copy link

I had the issue and solve via:

1. restore from backup

2. copy ENTIRE config directory (example, your setup may be different:  cp -R /homeassistant/zigbee2mqtt/* /root/addon_configs/45df7312_zigbee2mqtt/zigbee2mqtt)

3. Run update again

All devices were present and everything works.

Just further updated to -02 without issues.

The -2 updated seem to have reverted to /homeassistant/zigbee2mqtt/ as that is the folder where data is being updated for me now. I did "mv /root/addon_configs/45df7312_zigbee2mqtt/zigbee2mqtt /root/addon_configs/45df7312_zigbee2mqtt/zigbee2mqtt.old" then rebooted and everything is working still.

@AXEBro
Copy link

AXEBro commented Dec 3, 2024

Hmm restoring from backup didn't work. I'm a bit confused about the unique id ... where do I find mine? I'm running HAOS, via a VM.
image

image

@QaDoPL
Copy link

QaDoPL commented Dec 3, 2024

For me 1.42.0-1 works perfectly without any issued. Will keep this version now.
Lucky me i don't even made backup before update
And glad few of mine devices starting be recognized.

Core 2024.11.3
Supervisor 2024.11.4
Operating System 13.2

ConBee II adapter

@Dominic121282
Copy link

I still have 1.41.0-1.
Should I update to 1.42.0-2 or not?

@AXEBro
Copy link

AXEBro commented Dec 3, 2024

so my path looks like this:
/hassio/addon/45df7312_zigbee2mqtt/config

now - I have to figure out where that addon directory is - or maybe I need to create the whole path? addon/45df7312_zigbee2mqtt/config ?

@vgdh
Copy link

vgdh commented Dec 3, 2024

z2m in docker should check if the /addon_config/zigbee2mqtt is empty and copy all the files from the old /config/zigbee2mqtt directory to the new one.
After that it could change the path in the config automatically and call it a day.
After some time deprecate the old path usage.
And that will be smooth for all the users.

@Koenkk
Copy link
Contributor

Koenkk commented Dec 3, 2024

I still have 1.41.0-1. Should I update to 1.42.0-2 or not?

This upgrade should be fine! I think for users that already upgraded to 1.42.0-1 and now want to upgrade to 1.42.0-2, they should change the data path to /addon_config/zigbee2mqtt (I cannot test it atm, would be nice if someone else could confirm)

@Pferdebockwurst
Copy link

Pferdebockwurst commented Dec 3, 2024

I still have 1.41.0-1. Should I update to 1.42.0-2 or not?

This upgrade should be fine! I think for users that already upgraded to 1.42.0-1 and now want to upgrade to 1.42.0-2, they should change the data path to /addon_config/zigbee2mqtt (I cannot test it atm, would be nice if someone else could confirm)

Does this apply to the users who upgraded to 1.42.0-1 and have a working setup because they moved the files according the release notes?

@Koenkk
Copy link
Contributor

Koenkk commented Dec 3, 2024

Does this apply to the users who upgraded to 1.42.0-1 and have a working setup because they moved the files according the release notes?

Yes (I think)

@dpgh947
Copy link

dpgh947 commented Dec 3, 2024

I had installed 1.42.0-1 in a test HA and without doing anything with it, the data_path field was initially set to the new location /addon_config/zigbee2mqtt

I just installed the 0-2 level there, and it has now reverted to /config/zigbee2mqtt, so I assume from this that we should not have carried out the move yet after all.

What a mess.

@Koenkk
Copy link
Contributor

Koenkk commented Dec 3, 2024

@dpgh947 could you check if if works again after changing the data path to /addon_config/zigbee2mqtt?

@dpgh947
Copy link

dpgh947 commented Dec 3, 2024

@dpgh947 could you check if if works again after changing the data path to /addon_config/zigbee2mqtt?

My main live setup is working fine now with the files in the new location, this is just what I saw when I installed the addon on a test HA - it isn't running or configured at all on there, I was just seeing what the data_path was initially set to. So I assume that any more interim updates to the addon before the big change that is coming will revert the data_path field to /config again??

@stefanuytterhoeven
Copy link

What is going on?
I have hassos on rpi4.
currently mqtt on 1.42.0-1.
homeassistant/zigbee2mqtt as directory
everything works
now i see a FIX ?
what do i have to do????

what is the fix doing? does it create a new directory and copies the files from the original place?
Does anyone know what's happening?

@Delta1977
Copy link

z2m in docker should check if the /addon_config/zigbee2mqtt is empty and copy all the files from the old /config/zigbee2mqtt directory to the new one.

After that it could change the path in the config automatically and call it a day.

After some time deprecate the old path usage.

And that will be smooth for all the users.

The Migration is in v2.0 Branch #649

@Delta1977
Copy link

One hint from my side:

If I move the folders via cli then all is ok. If I move it with vscode add-on then something goes wrong and z2m UI is empty.

@AXEBro
Copy link

AXEBro commented Dec 3, 2024

not sure what's wrong with my install but I moved to addon_config ... but still seeing errors, and zigbee2mqtt is not starting:
Starting Zigbee2MQTT without watchdog.
[2024-12-03 12:18:22] info: z2m: Logging to console, file (filename: log.log)
[2024-12-03 12:18:22] info: z2m: Starting Zigbee2MQTT version 1.42.0 (commit #unknown)
[2024-12-03 12:18:22] info: z2m: Starting zigbee-herdsman (2.1.9)
[2024-12-03 12:18:22] warning: zh:ezsp: 'ezsp' driver is deprecated and will only remain to provide support for older firmware (pre 7.4.x). Migration to 'ember' is recommended. If using Zigbee2MQTT see Koenkk/zigbee2mqtt#21462
[2024-12-03 12:18:22] error: zh:ezsp:ezsp: Connection attempt 1 error: Error: Error: No such file or directory, cannot open /dev/serial/by-id/usb-ITEAD_SONOFF_Zigbee_3.0_USB_Dongle_Plus_V2_20220714181458-if00
[2024-12-03 12:18:27] error: zh:ezsp:ezsp: Connection attempt 2 error: Error: Error: No such file or directory, cannot open /dev/serial/by-id/usb-ITEAD_SONOFF_Zigbee_3.0_USB_Dongle_Plus_V2_20220714181458-if00
[2024-12-03 12:18:37] error: zh:ezsp:ezsp: Connection attempt 3 error: Error: Error: No such file or directory, cannot open /dev/serial/by-id/usb-ITEAD_SONOFF_Zigbee_3.0_USB_Dongle_Plus_V2_20220714181458-if00

@ki4hrg
Copy link

ki4hrg commented Dec 3, 2024

Reupping here from a separate issue I had opened - I also ran into issues with a device I added between -1 and -2 disappearing. Here's the sequence of events I was dealing with:

  1. Upgrade to 1.42.0-1, all devices were missing
  2. Extract z2m files from my most recent full backup and place in new (addon-specific) directory; all devices are back except for one device I added after the backup from which I was restoring
  3. Manually re-pair the missing device (a smart plug)
  4. Upgrade to 1.42.0-2, all devices are present except for the smart plug I re-paired in testing #3
  5. Manually re-pair the smart plug again

@xunleii
Copy link

xunleii commented Dec 3, 2024

Before upgrading to version 1.42.0-2, I would like to confirm: if I started using Z2MQTT with version 1.42.0-1, will I need to re-pair all devices after the upgrade, or is there a way to migrate everything beforehand?

@Daemonentreiber
Copy link

Before upgrading to version 1.42.0-2, I would like to confirm: if I started using Z2MQTT with version 1.42.0-1, will I need to re-pair all devices after the upgrade, or is there a way to migrate everything beforehand?

I just changed the config path to "/addon_config/zigbee2mqtt".

Let it make a backup before the update and you should be save in case something goes wrong.

@ki4hrg
Copy link

ki4hrg commented Dec 3, 2024 via email

@Dhaeyere
Copy link

Dhaeyere commented Dec 3, 2024

I'm totally lost... Have been trying to restore everything but the Addon won't start due to 502: Bad Gateway :-(

[19:43:48] INFO: Preparing to start... [19:43:48] INFO: Socat not enabled [19:43:48] INFO: Starting Zigbee2MQTT... Starting Zigbee2MQTT without watchdog. [2024-12-03 19:43:54] info: z2m: Logging to console, file (filename: log.log) [2024-12-03 19:43:54] info: z2m: Starting Zigbee2MQTT version 1.42.0 (commit #unknown) [2024-12-03 19:43:54] info: z2m: Starting zigbee-herdsman (2.1.9) [2024-12-03 19:43:55] error: z2m: Error while starting zigbee-herdsman [2024-12-03 19:43:55] error: z2m: Failed to start zigbee [2024-12-03 19:43:55] error: z2m: Check https://www.zigbee2mqtt.io/guide/installation/20_zigbee2mqtt-fails-to-start.html for possible solutions [2024-12-03 19:43:55] error: z2m: Exiting... [2024-12-03 19:43:55] 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)

Zigbee2MQTT
Current version: 1.42.0-2

Home Assistant

Core
2024.11.3
Supervisor
2024.11.4
Operating System
13.2
Frontend
20241106.2

@AXEBro
Copy link

AXEBro commented Dec 3, 2024

eventually got things working..

what's strange is "addon_config/zigbee2mqtt" doesn't work for me. but "/config/zigbee2mqtt" works on 1.42.0-2

lots of smaller devices are showing as offline - but i think will eventually come back. like remotes - on first use, they flip from offline to online. just need to walk around and push buttons, i guess.

@xunleii
Copy link

xunleii commented Dec 3, 2024

@Daemonentreiber @AXEBro Thanks for your response. I confirm, just copying /addon_configs/xxxx_zigbee2mqtt to /homeassistant/zigbee2mqtt before the upgrade works perfectly (I just stopped Z2MQTT before the upgrade but should no change anything).

@Koenkk
Copy link
Contributor

Koenkk commented Dec 3, 2024

Let's continue in Koenkk/zigbee2mqtt#25048

@Koenkk Koenkk closed this as completed Dec 3, 2024
@zigbee2mqtt zigbee2mqtt locked as too heated 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
None yet
Projects
None yet
Development

No branches or pull requests