BLYNK
BLYNK.IO       📲 GETTING STARTED       📗 DOCS       ❓HELP CENTER       👉 SKETCH BUILDER

Blynk 2.0 and MQTT

https://nodered.org/docs/getting-started/raspberrypi

Pete.

So your suggestion is to upgrade Node-Red version?

No…

Running as a service

The install script for the Pi also sets it up to run as a service. This means it can run in the background and be enabled to automatically start on boot.

The following commands are provided to work with the service:

  • node-red-start - this starts the Node-RED service and displays its log output. Pressing Ctrl-C or closing the window does not stop the service; it keeps running in the background
  • node-red-stop - this stops the Node-RED service
  • node-red-restart - this stops and restarts the Node-RED service
  • node-red-log - this displays the log output of the service

You can also start the Node-RED service on the Raspberry Pi OS Desktop by selecting the Menu -> Programming -> Node-RED menu option.

Pete.

Thank you for the suggestions, but the problem is that I am getting: “node-red-stop is not recognized as an internal or external command, operable program or batch file.”
Currently Node-Red is running as service

What type of machine and OS is this running on?

Searching for "node-red-stop is not recognized as an internal or external command` returns several solutions for windows based installations.

Pete.

Yes I tried this search, but I am running Node-Red on Ubuntu virtual machine (digital ocean)

Have you tried issuing these as sudo commands?

Pete.

Yes, outputs “command not found”

What responses do you get to…

node --version

and

npm --version

Also, what happens if you navigate to the folder where Node-Red is installed then issue the node-red-stop command?

Pete.

Node version is 8.10
npm version is 3.5.2
I successfully run this command: node-red --settings and I am attaching screenshot:

I assume that Node-Red is installed in ./node-red folder - this folder contains node_modules folder. settings.js and package.json so I think NR is installed there. node-red-stop outputs command not found (with and without sudo)

I’d recommend that you upgrade to the latest stable release of Node-Red, which is currently 2.0.6
This requires Node.js 12.17.x.

The “error port in use” message in your screenshot is because Node-Red was already running.

Pete.

Thank you for your suggestion. I am trying to upgrade it using the upgrade script from here:
https://nodered.org/docs/getting-started/raspberrypi
Unfortunately now I cant start node-red. It outputs the following error:

Okay, I assume that’s because you aren’t running it on a Raspberry Pi, but I can’t really be sure.

What version of Node.js and NPM are installed now?

Pete.

Thank you very much. I upgraded to Node.js 12 by adding --node12 to the upgrade script and now everything works. Blynk is connected too. Thank you very much for your time!

1 Like