Node red automatic reboot if that suddenly shutdown

Hi !

Someone know, is it possible to set a automatic restart if node red suddenly shutting down?
It would be good because, sometimes node red gone away, and i'm not always there to re launch the hole node red.

Thank you for your answer

I think a watchdog is what you want, but that is more the O/S than Node-Red.

(I'm not an expert in that sense of the word)

I rarely have node-red crash. It might be worth checking your logs, see what is crashing node-red. Usually it is a contrib node.

As for auto restart, are you running node-red as a service? There are options you can set to auto restart the service (no real need to reboot the device)

What OS are you using?

Actually, the node which cause that is not a contrib node

No i'm not running as service yet

Win 10, but in this week probably i switch to raspbarry

When you do that, install node-red using the recommended script and it will install a systemd service file. To enable that run
sudo systemctl enable nodered
and then it will automatically run on boot, and will automatically restart if node-red crashes.

pm2 is another option you can check, works on linux/windows/Mac and can launch and watchdog your process.

So what is causing your crash? A built in node? node-red runtime? Perhaps you could post logs from your crash & we can help you fix it?

If it is node-red or a built in node, it would be good if you could feedback on the forum or as an issue (for the devs to address it) -surely that is a better outcome than restarting/rebooting?

I already wrote about that here:

And i opened a issue thread on node red's github page.

1 Like

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