Node Red not updating to 4.x

I have been using Node Red for a while on Dietpi. I have been updating using the instructions in the software doc:

You can update Node-RED modules via programming IDE. To update the “node-red” core module, run the following command from console:

systemctl stop node-red
cd /mnt/dietpi_userdata/node-red
sudo -u nodered npm up --no-audit node-red
systemctl start node-red

The current Node-RED version can be read in the programming IDE in the burger menu at the right upper corner.

This does not work anymore. I am stuck on 3.11 while the latest is 4.1. Software reinstall does not help either.

Is there something I overlooked or do I need to open an issue ?

can you share some more system details

Required

  • DietPi version | cat /boot/dietpi/.version
  • Distro version | echo $G_DISTRO_NAME $G_RASPBIAN
  • Kernel version | uname -a
  • Architecture | dpkg --print-architecture
  • SBC model | echo $G_HW_MODEL_NAME or (EG: RPi3)

What I tested was to install Node-RED via dietpi-software on a fresh system.
Then, Node-Red 4.0.2 was installed.

In the internet I did not find any hints of upgrading which worked for me.
I tested these options, all without success. The system stayed at version 3.1.11:

An uninstall/install via dietpi-software uninstall 122 && dietpi-software install 122 led to a fresh 4.0.2 installation without the old flows from the 3.1.11 version.

So the next try could be to export the whole flows in the Node-RED UI , then do an uninstall/install via dietpi-software uninstall 122 && dietpi-software install 122 and afterwards import the flows again.
This will not be the best solution, because - depending on the nodes you use - some node’s credentials will not be valid any more and need to be entered again.

1 Like

Required

  • DietPi version |

G_DIETPI_VERSION_CORE=9
G_DIETPI_VERSION_SUB=6
G_DIETPI_VERSION_RC=0
G_GITBRANCH=‘beta’
G_GITOWNER=‘MichaIng’

  • Distro version | bullseye 0
  • Kernel version | Linux DietPi 6.1.21-v8+ #1642 SMP PREEMPT Mon Apr 3 17:24:16 BST 2023 aarch64 GNU/Linux
  • Architecture | arm64
  • SBC model | RPi 400 (aarch64)

Thanks, that gives me v4.02. I did try the reinstall version but that did not work. Not sure what the difference is.

Coincidentally someone else also had an issue: Node-red reinstall issue · Issue #7128 · MichaIng/DietPi · GitHub
And I pushed two dedicated fixes, on in our separate Node.js installer, and one in our Node-RED (re)install code.

When you find time, could you switch to the DietPi development branch, and test it again? Open Beta v9.6 | Please help testing and hardening our upcoming release · Issue #7136 · MichaIng/DietPi · GitHub

G_DEV_BRANCH dev
dietpi-software reinstall 122