# Openhabian Optional Components - Update Zigbee2MQTT 2.0.0

**URL:** <https://community.openhab.org/t/openhabian-optional-components-update-zigbee2mqtt-2-0-0/161420>\
**Category:** openHABian\
**Created:** [January 4, 2025, 9:11pm UTC](https://community.openhab.org/t/openhabian-optional-components-update-zigbee2mqtt-2-0-0/161420 "2025-01-04T21:11:15Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![Anpro](https://community.openhab.org/user_avatar/community.openhab.org/anpro/32/65888_2.png) [@Anpro](https://community.openhab.org/u/Anpro)\
**Post date:** [January 4, 2025, 9:11pm UTC](https://community.openhab.org/t/openhabian-optional-components-update-zigbee2mqtt-2-0-0/161420/1 "2025-01-04T21:11:15Z")

</div>

Hi all, has somebody tried to update zigbee2mqtt when installed via openhabian, cause for me it always stops the update.

There was an error or interruption during the execution of: │  
│ “20 | Optional Components” │  
│ │  
│ Please try again. If the error persists, please read │  
│ /opt/openhabian/docs/openhabian-DEBUG.md or │  
│ [https://github.com/openhab/openhabian/blob/main/docs/openhabian-DEBUG.md](https://github.com/openhab/openhabian/blob/main/docs/openhabian-DEBUG.md) how │  
│ to proceed.

Does this have to to with the change from npm to pnpm?

I run openhabian 64bit on pi4 with 4 GB.

BR

---

<div class="post-metadata">

**Author:** ![Nico\_Bunk](https://community.openhab.org/user_avatar/community.openhab.org/nico_bunk/32/76537_2.png) [@Nico\_Bunk](https://community.openhab.org/u/Nico_Bunk)\
**Post date:** [January 4, 2025, 9:21pm UTC](https://community.openhab.org/t/openhabian-optional-components-update-zigbee2mqtt-2-0-0/161420/2 "2025-01-04T21:21:32Z")

</div>

I don’t know if this is a related problem but after updating all my docker containers (also zigbee2mqtt to 2.0.0) this evening I had to add a line to the Z2M configuration.yaml as described here:

> **[Z2M 2.0.0: \`USB adapter discovery error (No valid USB adapter found)\` ·...](https://github.com/Koenkk/zigbee2mqtt/discussions/24364)**
>
> TL;DR Add adapter (likely zstack, see docs for more info) to your Zigbee2MQTT configuration.yaml, example: serial: adapter: zstack # \<-- Add this line port: /dev/ttyACM0 What changed? Koenkk/zigbee...

---

<div class="post-metadata">

**Author:** ![Anpro](https://community.openhab.org/user_avatar/community.openhab.org/anpro/32/65888_2.png) [@Anpro](https://community.openhab.org/u/Anpro)\
**Post date:** [January 4, 2025, 9:31pm UTC](https://community.openhab.org/t/openhabian-optional-components-update-zigbee2mqtt-2-0-0/161420/3 "2025-01-04T21:31:51Z")

</div>

Thx for your reply but I already had to add this line in the past with zigbee 1.4 to get my coordinator running: adapter: ember

And the problem is, that the update does not even start - I have to restart zigbee service but then I’m still on 1.42.0.

---

<div class="post-metadata">

**Author:** ![Anpro](https://community.openhab.org/user_avatar/community.openhab.org/anpro/32/65888_2.png) [@Anpro](https://community.openhab.org/u/Anpro)\
**Post date:** [January 4, 2025, 10:02pm UTC](https://community.openhab.org/t/openhabian-optional-components-update-zigbee2mqtt-2-0-0/161420/4 "2025-01-04T22:02:31Z")

</div>

I did it manually then - if somebody else struggles here the way I did it:

Install pnpm global:

```auto
sudo npm install -g pnpm

```

Stop Z2M:

```auto
sudo systemctl stop zigbee2mqtt

```

move config:

```auto
mv /opt/zigbee2mqtt/data/configuration.yaml /opt/zigbee2mqtt/data/configuration.yaml.bak

```

navigate to z2m:

```auto
cd /opt/zigbee2mqtt

```

pull changes from git with

```auto
git pull --no-rebase

```

run update script:

```auto
./update.sh

```

move config back:

```auto
mv /opt/zigbee2mqtt/data/configuration.yaml.bak /opt/zigbee2mqtt/data/configuration.yaml

```

start z2m:

```auto
sudo systemctl start zigbee2mqtt

```

THX to Koenkk at [Z2M - Update Infos](https://github.com/Koenkk/zigbee2mqtt/discussions/24198)

---

<div class="post-metadata">

**Author:** ![Annero](https://community.openhab.org/letter_avatar_proxy/v4/letter/a/a8b319/32.png) [@Annero](https://community.openhab.org/u/Annero)\
**Post date:** [January 5, 2025, 7:58am UTC](https://community.openhab.org/t/openhabian-optional-components-update-zigbee2mqtt-2-0-0/161420/5 "2025-01-05T07:58:26Z")

</div>

Thanks!!! Yesterday was a no go for me I gave up. Today found your steep by steep and all is working after five minutes.

---

<div class="post-metadata">

**Author:** ![ubeaut](https://community.openhab.org/user_avatar/community.openhab.org/ubeaut/32/119014_2.png) [@ubeaut](https://community.openhab.org/u/ubeaut)\
**Post date:** [January 5, 2025, 7:50pm UTC](https://community.openhab.org/t/openhabian-optional-components-update-zigbee2mqtt-2-0-0/161420/6 "2025-01-05T19:50:57Z")

</div>

I upgraded my Debian 12 to the version 2 and noticed that my Hue motion sensors were not working.  
It turned out the motion sensors were working but the rule I was using had a condition for the lux value.  
I noticed the lux value was not changing.  
Further investigation revealed the mqtt name had changed with V2.  
The illumination topic changed from **illuminance\_lux to illuminance**  
I changed my Incoming Value Transformations to: **JSONPATH:$.illuminance**  
and then it worked.  
I have not noticed if anything else has changed yet. It seems OK so far.  
This is something others may want to check after upgrading.

P.S I had to add adapter: zstack to get it to work.

```auto
serial:
  disable_led: true
  port: tcp://192.168.1.9:6638
  adapter: zstack
  baudrate: 115200

```

I am using a SLZB-06 co-ordinator.

---

<div class="post-metadata">

**Author:** ![Anpro](https://community.openhab.org/user_avatar/community.openhab.org/anpro/32/65888_2.png) [@Anpro](https://community.openhab.org/u/Anpro)\
**Post date:** [January 5, 2025, 8:00pm UTC](https://community.openhab.org/t/openhabian-optional-components-update-zigbee2mqtt-2-0-0/161420/7 "2025-01-05T20:00:58Z")

</div>

Yes those are also good hints!

For all who want to do the update better read the Zigbee2MQTT Release Discussion, linked [here](https://github.com/Koenkk/zigbee2mqtt/discussions/24198), because there are really some braking changes!

The question is to get the optional components update back working we need to bring up pnpm for the next opanhab release?

---

<div class="post-metadata">

**Author:** ![Larsen](https://community.openhab.org/user_avatar/community.openhab.org/larsen/32/95475_2.png) [@Larsen](https://community.openhab.org/u/Larsen)\
**Post date:** [January 5, 2025, 10:36pm UTC](https://community.openhab.org/t/openhabian-optional-components-update-zigbee2mqtt-2-0-0/161420/8 "2025-01-05T22:36:44Z")

</div>

> [@Anpro](#):
>
> The question is to get the optional components update back working we need to bring up pnpm for the next opanhab release?

that’s within the openhabian scripts, not openhab.  
They can be changed anytime, It just takes a PR and a merge. They’re updated online at each start.  
I wrote those zigbee2mqtt routines long ago but would be happy if somebody else jumps in and updates them for v2.  
I think we shouldn’t cover any major release updates, just plain installation of v2 and the update process within v2

---

<div class="post-metadata">

**Author:** ![Anpro](https://community.openhab.org/user_avatar/community.openhab.org/anpro/32/65888_2.png) [@Anpro](https://community.openhab.org/u/Anpro)\
**Post date:** [January 5, 2025, 11:41pm UTC](https://community.openhab.org/t/openhabian-optional-components-update-zigbee2mqtt-2-0-0/161420/9 "2025-01-05T23:41:56Z")

</div>

I would really like to help but I’m more of a smarthome enthusiast and not a developer, so I probably wouldn’t be much help.

---

<div class="post-metadata">

**Author:** ![clemenswunder](https://community.openhab.org/letter_avatar_proxy/v4/letter/c/57b2e6/32.png) [@clemenswunder](https://community.openhab.org/u/clemenswunder)\
**Post date:** [January 17, 2025, 7:28am UTC](https://community.openhab.org/t/openhabian-optional-components-update-zigbee2mqtt-2-0-0/161420/10 "2025-01-17T07:28:16Z")

</div>

Hi Larsen, same problem here. I’m very pleased to help testing

---

<div class="post-metadata">

**Author:** ![clemenswunder](https://community.openhab.org/letter_avatar_proxy/v4/letter/c/57b2e6/32.png) [@clemenswunder](https://community.openhab.org/u/clemenswunder)\
**Post date:** [January 17, 2025, 11:36am UTC](https://community.openhab.org/t/openhabian-optional-components-update-zigbee2mqtt-2-0-0/161420/11 "2025-01-17T11:36:12Z")

</div>

Tried:

1. execute on the command line: “npm install -g pnpm”
2. edit the file “/opt/openhabian/functions/nodejs-apps.bash”  
replace “npm ci” with “pnpm i --frozen-lockfile” (2 times, update and install section)
3. install “zigbee2mqtt” via “openhabian-config”
4. edit “/opt/zigbee2mqtt/data/configuration.yaml”  
add: “adapter: zstack”
5. reboot

Worked for me (serveral times)

---

<div class="post-metadata">

**Author:** ![Anpro](https://community.openhab.org/user_avatar/community.openhab.org/anpro/32/65888_2.png) [@Anpro](https://community.openhab.org/u/Anpro)\
**Post date:** [January 17, 2025, 10:35pm UTC](https://community.openhab.org/t/openhabian-optional-components-update-zigbee2mqtt-2-0-0/161420/12 "2025-01-17T22:35:31Z")

</div>

> [@clemenswunder](#):
>
> Worked for me (serveral times)

Mh if I try I get the same error as in my first post.

---

<div class="post-metadata">

**Author:** ![Larsen](https://community.openhab.org/user_avatar/community.openhab.org/larsen/32/95475_2.png) [@Larsen](https://community.openhab.org/u/Larsen)\
**Post date:** [January 18, 2025, 1:16am UTC](https://community.openhab.org/t/openhabian-optional-components-update-zigbee2mqtt-2-0-0/161420/13 "2025-01-18T01:16:07Z")

</div>

I fixed installation & update routine for v1.42.  
You need to choose the latest branch (01) for it.  
Be aware that this will install v1.42.  
So this is just a first step before supporting v2.

If you need/want v2 you have to do it manually by now.

---

<div class="post-metadata">

**Author:** ![Peck](https://community.openhab.org/letter_avatar_proxy/v4/letter/p/df705f/32.png) [@Peck](https://community.openhab.org/u/Peck)\
**Post date:** [March 4, 2025, 6:56pm UTC](https://community.openhab.org/t/openhabian-optional-components-update-zigbee2mqtt-2-0-0/161420/14 "2025-03-04T18:56:52Z")

</div>

Hi,  
I have installed z2m with openhabian-config. Now, when I try to update z2m I get the following error message

_Im Moment auf keinem Branch._  
_Bitte geben Sie den Branch an, welchen Sie zusammenführen möchten._  
_Siehe git-pull(1) für weitere Details._

- git pull \*

Any hints what to do in this case?

Peter

---

<div class="post-metadata">

**Author:** ![Brignoud](https://community.openhab.org/user_avatar/community.openhab.org/brignoud/32/34268_2.png) [@Brignoud](https://community.openhab.org/u/Brignoud)\
**Post date:** [March 13, 2025, 9:22am UTC](https://community.openhab.org/t/openhabian-optional-components-update-zigbee2mqtt-2-0-0/161420/15 "2025-03-13T09:22:51Z")

</div>

Sorry, after issuing the command: git pull --no rebase this error occur:  
“You are not currently on a branch  
Please specify which branch you want to merge with”  
Thanks

---

<div class="post-metadata">

**Author:** ![Anpro](https://community.openhab.org/user_avatar/community.openhab.org/anpro/32/65888_2.png) [@Anpro](https://community.openhab.org/u/Anpro)\
**Post date:** [April 16, 2025, 7:34pm UTC](https://community.openhab.org/t/openhabian-optional-components-update-zigbee2mqtt-2-0-0/161420/16 "2025-04-16T19:34:48Z")

</div>

Chatgpt says:

This means you’re currently in a **detached HEAD state** — most likely because you checked out a specific commit or tag instead of a branch like `master` or `main`.

To fix it, you need to switch back to the main branch before pulling updates.

Try one of these:

```auto
git checkout master

```

or

```auto
git checkout main

```

Then you can run:

```auto
git pull --no-rebase

```

If you’re unsure which branch is the main one, you can list all remote branches with:

```auto
git branch -r

```

Look for something like `origin/master` or `origin/main` and check it out accordingly.

hope it helps

---

<div class="post-metadata">

**Author:** ![Edwin\_de\_Boer](https://community.openhab.org/user_avatar/community.openhab.org/edwin_de_boer/32/36016_2.png) [@Edwin\_de\_Boer](https://community.openhab.org/u/Edwin_de_Boer)\
**Post date:** [September 27, 2025, 12:43pm UTC](https://community.openhab.org/t/openhabian-optional-components-update-zigbee2mqtt-2-0-0/161420/17 "2025-09-27T12:43:25Z")

</div>

I have tried all the above but still failing to start.  
Also updating the Zigbee stick, didn’t solved the problem.  
The service keeps restarting.  
Unfortunatly the log files aren’t being written, so no idee what the error is.

So, I started over and removed de Ziggbee2MQTT and then installed it again.  
Unfortunatly, still not te latest version?!?! But 1.43.0, but starting again and working fine.

Did the upgrade again and the issue still persists.  
In the log I see now the error:  
`Failed to start zigbee-herdsman`

> Set the log level to Debug.  
> The log output is the following:  
> [2025-09-27 14:38:49] debug: z2m: Removing old log directory ‘/var/log/zigbee2mqtt/2025-09-27.14-38-13al’  
> [2025-09-27 14:38:49] info: z2m: Logging to console, file (filename: log.log)  
> [2025-09-27 14:38:50] debug: z2m: Loaded state from file /opt/zigbee2mqtt/data/state.json  
> [2025-09-27 14:38:50] info: z2m: Starting Zigbee2MQTT version 2.6.1 (commit #d44463a3)  
> [2025-09-27 14:38:50] info: z2m: Starting zigbee-herdsman (6.0.4)  
> [2025-09-27 14:38:50] debug: z2m: Using zigbee-herdsman with settings: '“{“network”:{“panID”:54509,“extendedPanID”:[221,221,221,221,221,221,221,221],“channelList”:[25],“networkKey”:“HIDDEN”},“databasePath”:“/opt/zigbee\>  
> [2025-09-27 14:38:50] debug: zh:adapter:discovery: Connected devices: [{“path”:”/dev/ttyACM0”,“manufacturer”:“ITEAD”,“serialNumber”:“20230221151926”,“pnpId”:“usb-ITEAD\_SONOFF\_Zigbee\_3.0\_USB\_Dongle\_Plus\_V2\_20230221151926-if00”,“vendor\>  
> [2025-09-27 14:38:50] debug: zh:adapter:discovery: Unable to match USB adapter: zstack | /dev/serial/by-id/usb-ITEAD\_SONOFF\_Zigbee\_3.0\_USB\_Dongle\_Plus\_V2\_20230221151926-if00  
> [2025-09-27 14:38:50] debug: zh:controller: Starting with options '{“network”:{“networkKeyDistribute”:false,“networkKey”:“HIDDEN”,“panID”:54509,“extendedPanID”:[221,221,221,221,221,221,221,221],“channelList”:[25]},“serialPort”:{“path\>  
> [2025-09-27 14:38:50] info: zh:zstack:znp: Opening SerialPort with {“path”:”/dev/serial/by-id/usb-ITEAD\_SONOFF\_Zigbee\_3.0\_USB\_Dongle\_Plus\_V2\_20230221151926-if00”,“baudRate”:115200,“rtscts”:false,“autoOpen”:false}  
> [2025-09-27 14:38:50] info: zh:zstack:znp: Serialport opened  
> [2025-09-27 14:38:50] debug: zh:zstack:znp: → SREQ: SYS - ping - {“capabilities”:1}  
> [2025-09-27 14:38:50] debug: zh:zstack:unpi:writer: → frame [254,0,33,1,32]  
> [2025-09-27 14:38:50] info: zh:zstack:znp: Writing CC2530/CC2531 skip bootloader payload  
> [2025-09-27 14:38:50] debug: zh:zstack:unpi:writer: → buffer [239]  
> [2025-09-27 14:38:51] debug: zh:zstack:znp: → SREQ: SYS - ping - {“capabilities”:1}  
> [2025-09-27 14:38:51] debug: zh:zstack:unpi:writer: → frame [254,0,33,1,32]  
> [2025-09-27 14:38:51] info: zh:zstack:znp: Skip bootloader for CC2652/CC1352  
> [2025-09-27 14:38:51] error: z2m: Error while starting zigbee-herdsman  
> [2025-09-27 14:38:51] error: z2m: Failed to start zigbee-herdsman  
> [2025-09-27 14:38:51] error: z2m: Check ``[https://www.zigbee2mqtt.io/guide/installation/20\_zigbee2mqtt-fails-to-start\_crashes-runtime.html\`\`](https://www.zigbee2mqtt.io/guide/installation/20_zigbee2mqtt-fails-to-start_crashes-runtime.html%5C%60%5C%60) for possible solutions  
> [2025-09-27 14:38:51] error: z2m: Exiting…  
> [2025-09-27 14:38:51] error: z2m: Error: Error: Operation not supported, cannot set

No idea why this is so difficult to upgrade.

---

<div class="post-metadata">

**Author:** ![Larsen](https://community.openhab.org/user_avatar/community.openhab.org/larsen/32/95475_2.png) [@Larsen](https://community.openhab.org/u/Larsen)\
**Post date:** [September 27, 2025, 4:38pm UTC](https://community.openhab.org/t/openhabian-optional-components-update-zigbee2mqtt-2-0-0/161420/18 "2025-09-27T16:38:17Z")

</div>

> [@Edwin\_de\_Boer](#):
>
> No idea why this is so difficult to upgrade.

v2 is a major update with a few breaking changes. It brings additional requirements:

- nodejs with at least v20
- pnpm

We will solve the requirements soon within openhabian. But the plain update still has to be done manually. If you can’t wait those steps have to be done:  
[https://www.zigbee2mqtt.io/guide/installation/01\_linux.html](https://www.zigbee2mqtt.io/guide/installation/01_linux.html)

But instead of starting z2m you have to run update.sh and then proceed.

Additional information here:  
[https://github.com/Koenkk/zigbee2mqtt/discussions/24198](https://github.com/Koenkk/zigbee2mqtt/discussions/24198)

---

<div class="post-metadata">

**Author:** ![Dom76](https://community.openhab.org/user_avatar/community.openhab.org/dom76/32/55887_2.png) [@Dom76](https://community.openhab.org/u/Dom76)\
**Post date:** [October 28, 2025, 10:03am UTC](https://community.openhab.org/t/openhabian-optional-components-update-zigbee2mqtt-2-0-0/161420/19 "2025-10-28T10:03:51Z")

</div>

1. Hello

2. **openhabian@openhabian** : **/opt/zigbee2mqtt $** git pull --no-rebase

---

<div class="post-metadata">

**Author:** ![Dom76](https://community.openhab.org/user_avatar/community.openhab.org/dom76/32/55887_2.png) [@Dom76](https://community.openhab.org/u/Dom76)\
**Post date:** [October 28, 2025, 11:12am UTC](https://community.openhab.org/t/openhabian-optional-components-update-zigbee2mqtt-2-0-0/161420/20 "2025-10-28T11:12:13Z")

</div>

And here’s the rest…

- **openhabian@openhabian** : **/opt/zigbee2mqtt $** git checkout master

What exactly should I send?

[Next page](https://community.openhab.org/t/openhabian-optional-components-update-zigbee2mqtt-2-0-0/161420.md?page=2)
