Zigbee2mqtt connection issue since new version

I must admit I’m not sure

Do you mean false?

Try the import again, if it doesn’t work you will do the test without encryption

Are the flows RFlink? Is that it?

@VonOx
I tried reinstalling Node Red
What had to happen, happened
image
So I reinstalled Node Red: no issues
I didn’t want to restore my old flows
I recreated my Xiaomi server gateway node with the old parameters: no issues
And I recreated the Serial IN and Serial OUT nodes with their old parameters and it crashed
I put back my Xiaomi flow, everything works
I restored my old Xiaomi and RfLink flows, taking care to remove the Serial nodes, everything is fine
As soon as I redeploy with the Serial nodes: Server connection lost

Here are the Node Red logs

Welcome to Node-RED
===================

4 Apr 20:28:03 - [info] Node-RED version: v2.2.2
4 Apr 20:28:03 - [info] Node.js  version: v14.18.2
4 Apr 20:28:03 - [info] Linux 5.10.103-v8+ arm64 LE
4 Apr 20:28:04 - [info] Loading palette nodes
4 Apr 20:28:07 - [info] Settings file  : /data/settings.js
4 Apr 20:28:07 - [info] Context store  : 'default' [module=memory]
4 Apr 20:28:07 - [info] User directory : /data
4 Apr 20:28:07 - [warn] Projects disabled : editorTheme.projects.enabled=false
4 Apr 20:28:07 - [info] Flows file     : /data/flows.json
4 Apr 20:28:07 - [info] Server now running at http://127.0.0.1:1880/
4 Apr 20:28:07 - [warn]

---------------------------------------------------------------------
Your flow credentials file is encrypted using a system-generated key.

If the system-generated key is lost for any reason, your credentials
file will not be recoverable, you will have to delete it and re-enter
your credentials.

You should set your own key using the 'credentialSecret' option in
your settings file. Node-RED will then re-encrypt your credentials
file using your chosen key the next time you deploy a change.
---------------------------------------------------------------------

4 Apr 20:28:07 - [info] Starting flows

> node-red-docker@2.2.2 start /usr/src/node-red
> node $NODE_OPTIONS node_modules/node-red/red.js $FLOWS "--userDir" "/data"

4 Apr 20:28:15 - [info]

Welcome to Node-RED
===================

4 Apr 20:28:15 - [info] Node-RED version: v2.2.2
4 Apr 20:28:15 - [info] Node.js  version: v14.18.2
4 Apr 20:28:15 - [info] Linux 5.10.103-v8+ arm64 LE
4 Apr 20:28:16 - [info] Loading palette nodes
4 Apr 20:28:20 - [info] Settings file  : /data/settings.js
4 Apr 20:28:20 - [info] Context store  : 'default' [module=memory]
4 Apr 20:28:20 - [info] User directory : /data
4 Apr 20:28:20 - [warn] Projects disabled : editorTheme.projects.enabled=false
4 Apr 20:28:20 - [info] Flows file     : /data/flows.json
4 Apr 20:28:20 - [info] Server now running at http://127.0.0.1:1880/
4 Apr 20:28:20 - [warn]

---------------------------------------------------------------------
Your flow credentials file is encrypted using a system-generated key.

If the system-generated key is lost for any reason, your credentials
file will not be recoverable, you will have to delete it and re-enter
your credentials.

You should set your own key using the 'credentialSecret' option in
your settings file. Node-RED will then re-encrypt your credentials
file using your chosen key the next time you deploy a change.
---------------------------------------------------------------------

4 Apr 20:28:20 - [info] Starting flows

> node-red-docker@2.2.2 start /usr/src/node-red
> node $NODE_OPTIONS node_modules/node-red/red.js $FLOWS "--userDir" "/data"

I tried to find out where this could come from, after that I don’t know what to do.

Apart from asking the question in the node-red community, I don’t really know what to do. There’s nothing in the logs except a restart during the startup of the flows.

Sorry for not being able to help more.

Thanks anyway
Good night

Here is my failed attempt

in sudo nano /var/lib/node-red/settings.js

I uncommented //credentialSecret: "a-secret-key",
and changed it to (this is an example)

credentialSecret: "adfgjjsdbkqmf25vdDGdj",

I restarted the docker node_red

I did the same on both 32-bit and 64-bit versions with the same code.
I redeployed my flows on the 32-bit version so that it would be re-encrypted with the new code and then exported.

Imported on the 64-bit version but still crashing on deployment.

@Psoy can you try to recreate your node red container with --group-add dialout in addition to your docker run command

@bjm I think you’re good to go to recreate your flow(s) :neutral_face:

I restored the original //credentialSecret: « a-secret-key ».
I deleted serial-port in and serial-port out as well as node-red-node-serialport in Manage palette, deployed the flows, exported, imported into the 64-bit version, no crashes so far.
I recreate serial-port in the new one, fingers crossed.

I missed it, it crashed

I installed node-red-node-serialport version 0.15.0 which worked on my 32-bit system
https://www.npmjs.com/package/node-red-node-serialport/v/0.15.0

In the terminal to open a Shell in docker

$ docker exec -it node_red /bin/bash

This returns
bash-5.0#
I copy the following command at the end

npm i node-red-node-serialport@0.15.0

It processes and finally returns this

 notice created a lockfile as package-lock.json. You should commit this file.
+ node-red-node-serialport@0.15.0
added 48 packages from 37 contributors and audited 338 packages in 60.866s

45 packages are looking for funding
  run `npm fund` for details

found 4 critical severity vulnerabilities
  run `npm audit fix` to fix them, or `npm audit` for details

As there are 4 critical vulnerabilities I do

npm audit fix

As suggested
Then

exit

and

docker restart node_red

Here I am with a node-red-node-serialport version 0.15.0

Serial in enabled no bug.
Next up tomorrow for Serial out

The same issue is known, build problem

Hello @VonOx
where does this line go?
because I copied this:

docker run -d \
--log-opt max-size=10m \
--restart=always \
--privileged \
-u root \
--network=host \
--name node_red \
-v /var/lib/node-red:/data \
nodered/node-red
--group-add dialout

and I got this:

14d574b7875d8de709dbd477babf642c0a9c76fad82b9de77784163309aba71d
-bash: --group-add: command not found

docker run -d \
--log-opt max-size=10m \
--restart=always \
--privileged \
-u root \
--network=host \
--name node_red \
--group-add dialout \
-v /var/lib/node-red:/data \
nodered/node-red

thanks @VonOx
but it doesn’t change anything

Is the command not running or is Node-RED still crashing?

By the way, why the -u root?

It still crashes

It’s in Pierre-Gilles’ tutorial, he explains it, but I’m not at that level anymore :face_exhaling:

@bjm, @VonOx
Well, I followed your post to go back to 0.15.0. :grin: :grin:. And everything is back to normal, everything works, I find all the values of my sensors in the debug. So as @VonOx commented, the problem comes from the update of the palette « node-red-node-serialport 1.0.1 ». Staying on version 0.15.0 works well and is very satisfying for me.
Thanks to both of you, I can continue developing my scenes :smiley:

Psoy

7h

@bjm
I took the liberty of integrating your manipulation into the RFLink tutorial and waiting for the bug to be fixed, I hope you won’t mind :wink:
In any case, thank you again

You did well.
I think we also need to open a post with our issue as the title for those who will search on the forum, because here we are on the Ziegbee2mqtt post

Nice little comeback
It’s not easy :face_exhaling: because zigbee2Mqtt is crashing, while Node-red is working correctly again. And now I have removed Node red and zig2Mqtt (reinstalled) is working correctly. I will wait a few days before reinstalling node-red. To be continued

Yes, that would be better :wink:

As you always have problems with Ziegbee2mqt, I removed « node-red-node-serialport 0.15.0 » and did in the Shell

npm rebuild --node-red-node-serialport

This did nothing.
I reinstalled « node-red-node-serialport 1.0.1 » from the Node-Red software
Strangely, it shows « node-red-node-serialport 0.15.0 »
I did the automatic update twice, because the first one does not work.
Restart docker Node-red and do in the Shell.

npm rebuild --build-from-source

I test version 1.0.1
This still crashes.

I reinstall version 0.15.0 as before.
Curiously, this time it finds no vulnerabilities.
And Node-red works (I test with a switch)

I install Ziegbee2mqt I have an ADSL connection so it takes time.
I have the impression that the installation crashed.
I uncheck « Enable Ziegbee2mqt » then re-check it.
And I see the validation checkmarks appear in the image.
As it is already 1 a.m., I stop there.

This morning I start with an update of Gladys

sudo apt update
sudo apt upgrade

There is a docker update.

I configure 1 Xiaomi button and another Sonoff
These work.

I check that my Rflink switch still works as well.