Raspberry pi on Bookworm

Can you run
sudo apt update
and show us what you see?

pi@oh:~ $ sudo apt update
TalĂĄlat:1 http://deb.debian.org/debian bookworm InRelease
LetĂśltĂŠs:2 http://deb.debian.org/debian-security bookworm-security InRelease [48,0 kB]
LetĂśltĂŠs:3 http://deb.debian.org/debian bookworm-updates InRelease [52,1 kB]
TalĂĄlat:4 https://download.docker.com/linux/debian bookworm InRelease
TalĂĄlat:5 https://deb.nodesource.com/node_18.x nodistro InRelease
TalĂĄlat:6 http://archive.raspberrypi.com/debian bookworm InRelease
LetĂśltve 100 kB 2mp alatt (49,5 kB/s)
CsomaglistĂĄk olvasĂĄsa... KĂŠsz
Függőségi fa építése... Kész
Állapotinformåciók olvasåsa... KÊsz
Minden csomag naprakĂŠsz.

Means all packages are up to date.

Also it would be nice, if the install script would ask at the end :

  1. Should node-red auto-start as a daemon every time the RPi starts?
  2. Just start now here in this console?
  3. I will start it manually later by typing "node-red"

I know it requires sudo to create an auto-starting daemon, so maybe if the interactive question is YES, than it should download a secondary bash to execute it separately, and ask for a sudo password?

So it has enabled the nodesource repository. What does this command show?
apt policy nodejs

pi@oh:~ $ apt policy nodejs
nodejs:
  TelepĂ­tve: 18.19.0+dfsg-6~deb12u1
  JelĂślt:    18.19.0+dfsg-6~deb12u1
  VerziĂłtĂĄblĂĄzat:
 *** 18.19.0+dfsg-6~deb12u1 500
        500 http://deb.debian.org/debian-security bookworm-security/main arm64 Packages
        100 /var/lib/dpkg/status
     18.19.0-1nodesource1 500
        500 https://deb.nodesource.com/node_18.x nodistro/main arm64 Packages
     18.18.2-1nodesource1 500
        500 https://deb.nodesource.com/node_18.x nodistro/main arm64 Packages
     18.18.1-1nodesource1 500
        500 https://deb.nodesource.com/node_18.x nodistro/main arm64 Packages
     18.18.0-1nodesource1 500
        500 https://deb.nodesource.com/node_18.x nodistro/main arm64 Packages
     18.17.1-1nodesource1 500
        500 https://deb.nodesource.com/node_18.x nodistro/main arm64 Packages
     18.17.0-1nodesource1 500
        500 https://deb.nodesource.com/node_18.x nodistro/main arm64 Packages
     18.16.1-1nodesource1 500
        500 https://deb.nodesource.com/node_18.x nodistro/main arm64 Packages
     18.16.0-1nodesource1 500
        500 https://deb.nodesource.com/node_18.x nodistro/main arm64 Packages
     18.15.0-1nodesource1 500
        500 https://deb.nodesource.com/node_18.x nodistro/main arm64 Packages
     18.14.2-1nodesource1 500
        500 https://deb.nodesource.com/node_18.x nodistro/main arm64 Packages
     18.14.1-1nodesource1 500
        500 https://deb.nodesource.com/node_18.x nodistro/main arm64 Packages
     18.14.0-1nodesource1 500
        500 https://deb.nodesource.com/node_18.x nodistro/main arm64 Packages
     18.13.0+dfsg1-1 500
        500 http://deb.debian.org/debian bookworm/main arm64 Packages
     18.13.0-1nodesource1 500
        500 https://deb.nodesource.com/node_18.x nodistro/main arm64 Packages
     18.12.0-1nodesource1 500
        500 https://deb.nodesource.com/node_18.x nodistro/main arm64 Packages
     18.11.0-1nodesource1 500
        500 https://deb.nodesource.com/node_18.x nodistro/main arm64 Packages
     18.10.0-1nodesource1 500
        500 https://deb.nodesource.com/node_18.x nodistro/main arm64 Packages
     18.9.1-1nodesource1 500
        500 https://deb.nodesource.com/node_18.x nodistro/main arm64 Packages
     18.9.0-1nodesource1 500
        500 https://deb.nodesource.com/node_18.x nodistro/main arm64 Packages
     18.8.0-1nodesource1 500
        500 https://deb.nodesource.com/node_18.x nodistro/main arm64 Packages
     18.7.0-1nodesource1 500
        500 https://deb.nodesource.com/node_18.x nodistro/main arm64 Packages
     18.6.0-1nodesource1 500
        500 https://deb.nodesource.com/node_18.x nodistro/main arm64 Packages
     18.5.0-1nodesource1 500
        500 https://deb.nodesource.com/node_18.x nodistro/main arm64 Packages
     18.4.0-1nodesource1 500
        500 https://deb.nodesource.com/node_18.x nodistro/main arm64 Packages
     18.3.0-1nodesource1 500
        500 https://deb.nodesource.com/node_18.x nodistro/main arm64 Packages
     18.2.0-1nodesource1 500
        500 https://deb.nodesource.com/node_18.x nodistro/main arm64 Packages
     18.1.0-1nodesource1 500
        500 https://deb.nodesource.com/node_18.x nodistro/main arm64 Packages
     18.0.0-1nodesource1 500
        500 https://deb.nodesource.com/node_18.x nodistro/main arm64 Packages

TelepĂ­tve: 18.19.0+dfsg-6~deb12u1 << Means : Installed
JelĂślt: 18.19.0+dfsg-6~deb12u1 << Means: Marked

That is a nuisance, the bookworm repository has the same version as nodejs and it is picking up the one from the debian repo, which does not include npm. I don't think there is much the script can do about that.
If you ran the script with --node20 then there would not be a problem.

1 Like

FYI - I just tried installing NR on my Pi5/bookworm and got the same issue

Running Node-RED install for user pi at /home/pi on debian


This can take 20-30 minutes on the slower Pi versions - please wait.

  Stop Node-RED                       ✔
  Remove old version of Node-RED      ✔
  Remove old version of Node.js       ✔   18.19.0-1nodesource1
  Install Node 18.19.0+dfsg-6~deb12u1   ✘   Bad install:  Node.js v18.19.0  Npm missing - Exit
  Clean npm cache                     
  Install Node-RED core               
  Move global nodes to local          
  Npm rebuild existing nodes          
  Install extra Pi nodes              
  Add shortcut commands               
  Update systemd script               
                                      

Any errors will be logged to   /var/log/nodered-install.log

Is it ok if you specify --node20

That worked fine :slight_smile:

Running Node-RED install for user pi at /home/pi on debian


This can take 20-30 minutes on the slower Pi versions - please wait.

  Stop Node-RED                       ✔
  Remove old version of Node-RED      ✔
  Remove old version of Node.js       ✔   18.19.0+dfsg-6~deb12u1
  Install Node 20.10.0-1nodesource1   ✔   v20.10.0   Npm 10.2.3
  Clean npm cache                     ✔
  Install Node-RED core               ✔   3.1.3
  Move global nodes to local          -
  Npm rebuild existing nodes          ✔
  Install extra Pi nodes              ✔
  Add shortcut commands               ✔
  Update systemd script               ✔

Script should be fixed now - so default of node 18 should now work on bookworm 64bit.

4 Likes

An issue I have observed with bookworm on a pi4/400 (haven’t got a pi5 on which to compare) is that nodes which use serial devices (e.g. USB z-wave / zigbee dongles) fail to handle flow restarts / deployments correctly. After restarting the serial port appears locked within the flow even though it is the nodered process that locked it. Restarting the process fixes it until the next deployment. This affects both the built in serial in / out nodes as well as contributed nodes that open serial ports

Do you happen to be on Node20?

I ask, as the popular node js module serialport seems to have popped up with that issue under node 20, and this module is used to drive nodes that need serial port.

I had users reporting that issue to me (zwave js node red module) and downgrading to node 18 sorts it. I believe it’s upstream with serialport and Node20

EDIT
just checked the serialport repo - and a few reports under Node20 share the same experience.

When a serial port is closed, it cannot be re-opened

Error Resource temporarily unavailable Cannot lock port

I think the devs are looking to fix it soon, and it appears to have surfaced under Node20

Example report: Cannot reconnect to port on linux, OSX is working fine ¡ Issue #2685 ¡ serialport/node-serialport ¡ GitHub

1 Like

Yep. And it was actually your zwave-js node in which I first noticed it. I assumed it was some upstream related issue since it appeared to affect all nodes that use serial ports, not just yours nor only with certain devices. Not an issue worth downgrading for me personally and hopefully it will get fixed sooner than later :slightly_smiling_face:

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.