RPI Serial hangups

node-red-log produces "command not found"
I installed all Node red via Pete Scargill's script.
Colin I have tried all measures including a full reboot and have found that stop- and restart of node red is enough to sort it for a few days. The terminal during restart all looks normal.
edit *** the last few lines are new. I will sort that. I don't think it is relevant.

Start Node-RED

Once Node-RED has started, point a browser at http://10.0.0.50:1880
On Pi Node-RED works better with the Firefox or Chrome browser

Use node-red-stop to stop Node-RED
Use node-red-start to start Node-RED again
Use node-red-log to view the recent log output
Use sudo systemctl enable nodered.service to autostart Node-RED at every boot
Use sudo systemctl disable nodered.service to disable autostart on boot

To find more nodes and example flows - go to http://flows.nodered.org

Starting as a systemd service.
Started Node-RED graphical event wiring tool.
30 Jan 17:49:37 - [info]
Welcome to Node-RED

30 Jan 17:49:37 - [info] Node-RED version: v0.19.4
30 Jan 17:49:37 - [info] Node.js version: v8.11.1
30 Jan 17:49:37 - [info] Linux 4.14.71-v7+ arm LE
30 Jan 17:49:43 - [info] Loading palette nodes
30 Jan 17:49:51 - [info] Dashboard version 2.13.0 started at /ui
30 Jan 17:49:52 - [info] Settings file : /home/pi/.node-red/settings.js
30 Jan 17:49:52 - [info] HTTP Static : /home/pi/.node-red/public
30 Jan 17:49:52 - [info] Context store : 'default' [module=memory]
30 Jan 17:49:52 - [info] User directory : /home/pi/.node-red
30 Jan 17:49:52 - [warn] Projects disabled : editorTheme.projects.enabled=false
30 Jan 17:49:52 - [info] Flows file : /home/pi/.node-red/flows.json
30 Jan 17:49:53 - [info] Server now running at http://127.0.0.1:1880/
30 Jan 17:49:53 - [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.

30 Jan 17:49:53 - [info] Starting flows
30 Jan 17:49:54 - [info] [tcp out:telnet] connecting to localhost:7072
30 Jan 17:49:59 - [info] [tcp out:telnet] connecting to localhost:7072
30 Jan 17:50:13 - [info] Started flows
30 Jan 17:50:13 - [info] [sqlitedb:c37d97a8.1b07c8] opened /home/pi/dbs/iot.db ok
30 Jan 17:50:13 - [info] [sqlitedb:c37d97a8.1b07c8] opened /home/pi/dbs/iot.db ok
30 Jan 17:50:13 - [info] [sqlitedb:c37d97a8.1b07c8] opened /home/pi/dbs/iot.db ok
30 Jan 17:50:13 - [info] [sqlitedb:c37d97a8.1b07c8] opened /home/pi/dbs/iot.db ok
30 Jan 17:50:13 - [info] serial port /dev/ttyAMA0 opened at 9600 baud 8N1
30 Jan 17:50:13 - [info] [mqtt-broker:fc8b5c33.494e8] Connected to broker: mqtt://127.0.0.1:1883
30 Jan 17:50:13 - [info] [tcp out:telnet] connected to localhost:7072
30 Jan 17:50:13 - [info] [tcp out:telnet] connected to localhost:7072
30 Jan 17:50:13 - [info] [mqtt-broker:7326ac84.630d14] Connection failed to broker: mqtt://localhost:1883
30 Jan 17:50:28 - [info] [mqtt-broker:7326ac84.630d14] Connection failed to broker: mqtt://localhost:1883
30 Jan 17:50:43 - [info] [mqtt-broker:7326ac84.630d14] Connection failed to broker: mqtt://localhost:1883
30 Jan 17:50:58 - [info] [mqtt-broker:7326ac84.630d14] Connection failed to broker: mqtt://localhost:1883