Error starting zigbee2mqtt

Hi There,

I am new here and have a problem. probably a noob question but I am really stuck.
I flashed a cc2531 installed all the software as discribed but when I start zigbee2mqtt i get this:

pi@Raspi4Jan:/opt/zigbee2mqtt $ npm start

zigbee2mqtt@1.15.0 start /opt/zigbee2mqtt
node index.js

Zigbee2MQTT:info 2020-10-16 15:57:44: Logging to console and directory: ‘/opt/zigbee2mqtt/data/log/2020-10-16.15-57-44’ filename: log.txt
Zigbee2MQTT:info 2020-10-16 15:57:45: Starting Zigbee2MQTT version 1.15.0 (commit #1bccc5d)
Zigbee2MQTT:info 2020-10-16 15:57:45: Starting zigbee-herdsman…
Zigbee2MQTT:error 2020-10-16 15:57:45: Error while starting zigbee-herdsman
Zigbee2MQTT:error 2020-10-16 15:57:45: Failed to start zigbee
Zigbee2MQTT:error 2020-10-16 15:57:45: Exiting…
Zigbee2MQTT:error 2020-10-16 15:57:45: Error: Error while opening serialport ‘Error: Error Resource temporarily unavailable Cannot lock port’
at Znp. (/opt/zigbee2mqtt/node_modules/zigbee-herdsman/dist/adapter/z-stack/znp/znp.js:136:32)
at ()
at /opt/zigbee2mqtt/node_modules/zigbee-herdsman/dist/adapter/z-stack/znp/znp.js:27:71
at new Promise ()
at __awaiter (/opt/zigbee2mqtt/node_modules/zigbee-herdsman/dist/adapter/z-stack/znp/znp.js:23:12)
at SerialPort. (/opt/zigbee2mqtt/node_modules/zigbee-herdsman/dist/adapter/z-stack/znp/znp.js:134:49)
at SerialPort._error (/opt/zigbee2mqtt/node_modules/zigbee-herdsman/node_modules/@serialport/stream/lib/index.js:198:14)
at /opt/zigbee2mqtt/node_modules/zigbee-herdsman/node_modules/@serialport/stream/lib/index.js:242:12
npm ERR! errno 1
npm ERR! zigbee2mqtt@1.15.0 start: node index.js
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the zigbee2mqtt@1.15.0 start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR! /home/pi/.npm/_logs/2020-10-16T13_57_45_835Z-debug.log

anybody any idea to help me?


Is modemmanager installed ?


apt-get purge modemmanager

Hi francisp,

Thnx for your reply but no succes.

pi@Raspi4Jan:~ $ sudo apt-get purge modemmanager
Pakketlijsten worden ingelezen… Klaar
Boom van vereisten wordt opgebouwd
De statusinformatie wordt gelezen… Klaar
Pakket ‘modemmanager’ is niet geïnstalleerd, en wordt dus niet verwijderd
0 opgewaardeerd, 0 nieuw geïnstalleerd, 0 te verwijderen en 1 niet opgewaardeerd.


I saw exactly this error on my HA installation earlier today. Had to reboot twice to clear it.

rebooted allready several times with no luck :hot_face:

This is the complet logfile:

0 info it worked if it ends with ok
1 verbose cli [ ‘/usr/bin/node’, ‘/usr/bin/npm’, ‘start’ ]
2 info using npm@6.14.8
3 info using node@v12.19.0
4 verbose run-script [ ‘prestart’, ‘start’, ‘poststart’ ]
5 info lifecycle zigbee2mqtt@1.15.0~prestart: zigbee2mqtt@1.15.0
6 info lifecycle zigbee2mqtt@1.15.0~start: zigbee2mqtt@1.15.0
7 verbose lifecycle zigbee2mqtt@1.15.0~start: unsafe-perm in lifecycle true
8 verbose lifecycle zigbee2mqtt@1.15.0~start: PATH: /usr/lib/node_modules/npm/node_modules/npm-lifecycle/node-gyp-bin:/opt/zigbee2mqtt/node_modules/.bin:/u$
9 verbose lifecycle zigbee2mqtt@1.15.0~start: CWD: /opt/zigbee2mqtt
10 silly lifecycle zigbee2mqtt@1.15.0~start: Args: [ ‘-c’, ‘node index.js’ ]
11 silly lifecycle zigbee2mqtt@1.15.0~start: Returned: code: 1 signal: null
12 info lifecycle zigbee2mqtt@1.15.0~start: Failed to exec start script
13 verbose stack Error: zigbee2mqtt@1.15.0 start: node index.js
13 verbose stack Exit status 1
13 verbose stack at EventEmitter. (/usr/lib/node_modules/npm/node_modules/npm-lifecycle/index.js:332:16)
13 verbose stack at EventEmitter.emit (events.js:314:20)
13 verbose stack at ChildProcess. (/usr/lib/node_modules/npm/node_modules/npm-lifecycle/lib/spawn.js:55:14)
13 verbose stack at ChildProcess.emit (events.js:314:20)
13 verbose stack at maybeClose (internal/child_process.js:1021:16)
13 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:286:5)
14 verbose pkgid zigbee2mqtt@1.15.0
15 verbose cwd /opt/zigbee2mqtt
16 verbose Linux 5.4.51-v7l+
17 verbose argv “/usr/bin/node” “/usr/bin/npm” “start”
18 verbose node v12.19.0
19 verbose npm v6.14.8
20 error code ELIFECYCLE
21 error errno 1
22 error zigbee2mqtt@1.15.0 start: node index.js
22 error Exit status 1
23 error Failed at the zigbee2mqtt@1.15.0 start script.
23 error This is probably not a problem with npm. There is likely additional logging output above.
24 verbose exit [ 1, true ]

You did flash the CC2531 with the Zigbee2mqtt firmware ?

yes I did, the coordinator version of 20190608 znp-prod.hex
reflashed again but stil not working.
getting desperate

Is user pi member of the group dialout?
Check with the command groups

If not, add with
sudo usermod -a -G dialout pi

Thank you all for the support.
What I did was make a complete fresh install of buster on my pi.
After that everything is working!!! :hugs: