GROUP SELECTION not working. NR 4.0.9

I seem to be having a lot of problems of late.

Today's quest is I'm trying to group some nodes.

THEY WON'T!

I've tried to group just a few, they too won't group.

Other nodes - near by - will group.

Want screen shots?
Though I can't see how it would help.

Oh, full run down of setup:

Andrew, you have made a lot of posts recently and written lots of words but every one of them are of no use to the maintainersbwithout the errors logged in the devtool console, a step by step what you did & the data/flow that caused it.

If you are not willing to share the flow on the main forum, you can DM me.

Please format your post like this.

version info

  • Node version: xxx (enter node -v)
  • Node-red version xxx
  • Browser kind: xxx (e.g chrome)
  • Browser version: Vxxx (eg V112.333)

steps you took

  1. Starting from empty edit
  2. Press ctrl+I
  3. Paste flow
  4. Etc

errors in your browsers devtools console (usually accessed via f12

Xxxxx

screenshots

Xxxxx

data /flows that caused your issue

[...]
1 Like

Ok, I am not exactly hitting the required things here.

These things are not predictable and I am really not dealing with them well.

I can post screen shots but I am not sure what good they will do.

Starting from an empty edit screen won't give me the problems I am seeing, as far as I know.
They are...... problems which are way outside my scope of knowledge.

dev tools Sorry. Browser's? Node-Red's?

I do - in some ways - fully appreciate it from the Dev's side of things.

If I know how to ..... force these things: I would.
I don't and so can't.

All I can do is show what is happening.

That is easy enough when I'm getting rogue errors and there are things to see.
But when I draw a box around some nodes and say ADD TO GROUP and nothing happens...

What am I supposed to do?

I'm not trying to be difficult. Believe me. As said: I have NO IDEA what is happening or how/why/etc.

I can't just reach into a magic hat and produce information I don't have.

Sorry, I hope you understand.

90% of that post is waffle :wink:

Your browser will have devtools and console where errors are written. You have been there before. You press f12 or similar.

I'll update my thread above to try and clarify what is required.

To be clear, the format I suggested included sample text - it is NOT a set of instructions, just a suggested posting format.

I'm not getting any ERRORS....

I group the nodes go to the menu in NR pick the group nodes.

The screen does nothing.

No errors.

I'll dig and see what I can find.

"that" post.... which one?

All of them :joy:

Well, I gave all the information I could/have/discovered.

If that isn't enough then I'm at a loss what to do.

There IS a problem there. It is beyond me. I can (if lucky) force it as what happened this morning - again.

But there are no promises it WILL happen.

All I can do is show people.

Andrew, we need the info as requested.

If there are no errors, then state that. But each time you encounter an issue, as one set of information, the above format works best for us.

Well the grouping problem has been...... fixed.

I grouped two nodes and dragged them around all the others and then moved them all (one by one) to add them to the group.

Give me a gun lead tranquiliser and I'll fix all my problems.
I don't need this.
REALLY DON'T

RPiOS Buster is very out of date and nodejs 18 is also the oldest still supported version for Node-red.
No idea if your recent problems are related to this but it might be wise to plan to update them.

Do you run a lot of other software on your Node-red Pies - databases, pihole, etc?
Do they run on SD cards or SSDs?
Do you use the desktop on a day to day basis? (I know you have said you use desktop tools for system admin tasks).

If I was buying a Pi as my main Node-red server today I'd consider the Pi 5 2GB.
The performance improvement when I upgraded from a 3B to a 4B and switched to an SSD was well worth the (not cheap) cost, though it's a significant effort to transfer everything.

I suspect there were compound issues relevant to all of Andrews recent posts.
I suspect it started when he imported flows into newer Node-RED (4.0.9) which uses some more modern syntaxes (like .hasOwn and this?.that etc) that WOULD have raised errors in the consle & would probably be the cause of the missing lines/nodes. Following that, the grouping and so forth are possibly compounded issues.

It is just a suspicion, unfortunately, without the relevant requested info this is pretty tricky to determine if this is a user/system issue or a real node-red problem.

I have a feeling Andrew is doing imports over VNC in an old version of chromium.

Andrew, you might find this flow useful. It is designed to send to MQTT using retained topics but you can simply dump it to a global variable and output to debug when needed if you prefer that.

[{"id":"16c80b3b.96b455","type":"inject","z":"d0860be6.7951b8","g":"22b622da.95bf8e","name":"","props":[{"p":"topic","vt":"str"}],"repeat":"21600","crontab":"","once":true,"onceDelay":0.1,"topic":"OS Info","x":95,"y":1040,"wires":[["a3b2034e.b6368","b2eada78.c69358","174f9b34.08c585","a81d73e6.f2b48","35352753.1c63d8","83f3c36b.fcf6","5102db3fc51c266f"]],"l":false},{"id":"5f6080b8.724c8","type":"function","z":"d0860be6.7951b8","g":"22b622da.95bf8e","name":"","func":"// @ts-ignore\nconst require = global.get('require')\n\nconst os = require('os')\nconst pay = msg.payload.split('\\n')\n\nmsg.var = \"INFO\"\nmsg.prop = \"system.server\"\nconst server = {}\n\nserver.hostname = os.hostname()\nserver.type = os.type()\nserver.os = pay[0]\nserver.last_reboot = new Date(pay[1])\nserver.release = os.release()\nserver.version = os.version()\n//server.platform = os.platform()\nserver.arch = os.arch()\nserver.endianness = os.endianness()\nserver.cpu = os.cpus()[0].model\nserver.cores = os.cpus().length\nserver.totalmem = Number.parseFloat( os.totalmem()/1073741824 ).toFixed(1) // GB\n\n// server.freemem = os.freemem()\n// server.loadavg = os.loadavg()\n// server.networkInterfaces = os.networkInterfaces()\n\nmsg.val = server //{}\n//msg.val.system = system\n\nreturn msg\n\n// cat /etc/os-release | grep -oP '^PRETTY_NAME=\\\"\\K.*?(?=\")'\n// lsb_release -a\n//     Description:    Debian GNU/Linux 10 (buster)","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":515,"y":1040,"wires":[["06e8df4b2381e872"]],"l":false},{"id":"a3b2034e.b6368","type":"exec","z":"d0860be6.7951b8","g":"22b622da.95bf8e","command":"cat /etc/os-release | grep -oP '^PRETTY_NAME=\\\"\\K.*?(?=\")'  && uptime -s","addpay":"","append":"","useSpawn":"false","timer":"","oldrc":false,"name":"Get OS Name & last reboot","x":340,"y":1040,"wires":[["5f6080b8.724c8"],[],[]]},{"id":"b2eada78.c69358","type":"exec","z":"d0860be6.7951b8","g":"22b622da.95bf8e","command":"ls -lact --full-time /etc |awk 'END {print $6,$7,$8}'","addpay":"","append":"","useSpawn":"false","timer":"","winHide":false,"oldrc":false,"name":"OS Install Dt","x":290,"y":1100,"wires":[["dde4c354.5ba12"],[],[]]},{"id":"dde4c354.5ba12","type":"function","z":"d0860be6.7951b8","g":"22b622da.95bf8e","name":"","func":"msg.var = \"INFO\"\nmsg.prop = \"system.server\"\nmsg.val = {}\n\nmsg.val.os_installed = new Date(msg.payload.trim())\n\nreturn msg\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":515,"y":1100,"wires":[["06e8df4b2381e872"]],"l":false},{"id":"cf70194f.ca8478","type":"function","z":"d0860be6.7951b8","g":"22b622da.95bf8e","name":"","func":"msg.var = \"INFO\"\nmsg.prop = \"system.nodered.last_restart\"\nmsg.val = msg.payload.trim().replace('+00:00','.000Z')\n\nreturn msg\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":515,"y":1160,"wires":[["06e8df4b2381e872"]],"l":false},{"id":"174f9b34.08c585","type":"exec","z":"d0860be6.7951b8","g":"22b622da.95bf8e","command":"sudo systemctl show nrmain | grep -oP 'ExecMainStartTimestamp=\\K.*' | xargs -0 date -Iseconds -u -d","addpay":"","append":"","useSpawn":"false","timer":"","winHide":false,"oldrc":false,"name":"Node-RED restarted last?","x":330,"y":1160,"wires":[["cf70194f.ca8478"],[],[]]},{"id":"a81d73e6.f2b48","type":"exec","z":"d0860be6.7951b8","g":"22b622da.95bf8e","command":"npm ls --depth=0 | grep -oP 'node-red\\@\\K.*'","addpay":"","append":"","useSpawn":"false","timer":"","winHide":false,"oldrc":false,"name":"Node-RED current version","x":340,"y":1220,"wires":[["b5575ac.eb4c1a8"],[],[]]},{"id":"b5575ac.eb4c1a8","type":"function","z":"d0860be6.7951b8","g":"22b622da.95bf8e","name":"","func":"msg.var = \"INFO\"\nmsg.prop = \"system.nodered.version\"\nmsg.val = msg.payload.trim()\n\nreturn msg\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":515,"y":1220,"wires":[["06e8df4b2381e872"]],"l":false},{"id":"35352753.1c63d8","type":"exec","z":"d0860be6.7951b8","g":"22b622da.95bf8e","command":"node --version","addpay":"","append":"","useSpawn":"false","timer":"","winHide":false,"oldrc":false,"name":"Node.js current version","x":330,"y":1280,"wires":[["2e54abd3.f445a4"],[],[]]},{"id":"2e54abd3.f445a4","type":"function","z":"d0860be6.7951b8","g":"22b622da.95bf8e","name":"","func":"msg.var = \"INFO\"\nmsg.prop = \"system.node.version\"\nmsg.val = msg.payload.trim()\n\nreturn msg\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":515,"y":1280,"wires":[["06e8df4b2381e872"]],"l":false},{"id":"cd99fc7f.3ed21","type":"function","z":"d0860be6.7951b8","g":"22b622da.95bf8e","name":"","func":"msg.var = \"INFO\"\nmsg.prop = \"system.node.npm_version\"\nmsg.val = msg.payload.trim()\n\nreturn msg\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":515,"y":1340,"wires":[["06e8df4b2381e872"]],"l":false},{"id":"83f3c36b.fcf6","type":"exec","z":"d0860be6.7951b8","g":"22b622da.95bf8e","command":"npm --version","addpay":"","append":"","useSpawn":"false","timer":"","winHide":false,"oldrc":false,"name":"npm current version","x":320,"y":1340,"wires":[["cd99fc7f.3ed21"],[],[]]},{"id":"5102db3fc51c266f","type":"http request","z":"d0860be6.7951b8","g":"22b622da.95bf8e","name":"NR Diagnostics","method":"GET","ret":"obj","paytoqs":"ignore","url":"https://home.knightnet.co.uk:1880/red/diagnostics","tls":"","persist":false,"proxy":"","authType":"","senderr":false,"headers":[],"x":300,"y":1400,"wires":[["d64c4be6b011e1a8"]]},{"id":"d64c4be6b011e1a8","type":"function","z":"d0860be6.7951b8","g":"22b622da.95bf8e","name":"","func":"msg.var = \"INFO\"\nmsg.prop = \"system.nodered.diagnostics\"\nmsg.val = msg.payload\n\nreturn msg\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":515,"y":1400,"wires":[["06e8df4b2381e872"]],"l":false}]

There is also this which tells you whether your currently installed node.js is an LTS version and what the current LTS version is:

[{"id":"f9f5e3edbfdb44a7","type":"function","z":"d0860be6.7951b8","g":"3aba606e3d187d8b","name":"function 4","func":"const releases = msg.payload\n\nconst latestLTS = releases.find((release) => release.lts)\n\nconst installedVersion = process.version\n\nconst installedDetails = releases.find((release) => release.version === installedVersion)\n\nconst isIninstalledLTS = installedDetails.lts !== false\n\nconsole.log(`Latest LTS version: ${latestLTS.version}, LTS: ${latestLTS.lts}`)\nconsole.log(`Installed version: ${installedVersion}. From details: ${installedDetails.version}, LTS ${installedDetails.lts}`);\n\nif (isIninstalledLTS === true) {\n    console.log('The installed version is an LTS version.');\n} else {\n    console.log('The installed version is not an LTS version.');\n}\n\nreturn {\n    isInstalledLTS: isIninstalledLTS,\n    installed: installedVersion,\n    installedDetails: installedDetails,\n    latestLTS: latestLTS,\n    releases: releases,\n}","outputs":1,"timeout":0,"noerr":0,"initialize":"","finalize":"","libs":[{"var":"process","module":"process"}],"x":500,"y":3680,"wires":[["6413c730059274c2"]]}]

1 Like

I'm not sure this would help Andrew, or confuse him more :wink:
It looks like it is somewhat customised for your particular install.

If you want to try it Andrew, then try this modified flow -

[{"id":"16c80b3b.96b455","type":"inject","z":"32bc1133.9bf706","name":"","props":[{"p":"topic","vt":"str"}],"repeat":"21600","crontab":"","once":true,"onceDelay":0.1,"topic":"OS Info","x":1205,"y":1140,"wires":[["a3b2034e.b6368","b2eada78.c69358","174f9b34.08c585","a81d73e6.f2b48","35352753.1c63d8","83f3c36b.fcf6","5102db3fc51c266f"]],"l":false},{"id":"5f6080b8.724c8","type":"function","z":"32bc1133.9bf706","name":"","func":"\n\nconst pay = msg.payload.split('\\n')\n\nmsg.var = \"INFO\"\nmsg.prop = \"system.server\"\nconst server = {}\n\nserver.hostname = os.hostname()\nserver.type = os.type()\nserver.os = pay[0]\nserver.last_reboot = new Date(pay[1])\nserver.release = os.release()\nserver.version = os.version()\n//server.platform = os.platform()\nserver.arch = os.arch()\nserver.endianness = os.endianness()\nserver.cpu = os.cpus()[0].model\nserver.cores = os.cpus().length\nserver.totalmem = Number.parseFloat( os.totalmem()/1073741824 ).toFixed(1) // GB\n\n// server.freemem = os.freemem()\n// server.loadavg = os.loadavg()\n// server.networkInterfaces = os.networkInterfaces()\n\nmsg.val = server //{}\n//msg.val.system = system\n\nreturn msg\n\n// cat /etc/os-release | grep -oP '^PRETTY_NAME=\\\"\\K.*?(?=\")'\n// lsb_release -a\n//     Description:    Debian GNU/Linux 10 (buster)","outputs":1,"timeout":"","noerr":0,"initialize":"","finalize":"","libs":[{"var":"os","module":"os"}],"x":1625,"y":1140,"wires":[["6837697c8f850add"]],"l":false},{"id":"a3b2034e.b6368","type":"exec","z":"32bc1133.9bf706","command":"cat /etc/os-release | grep -oP '^PRETTY_NAME=\\\"\\K.*?(?=\")'  && uptime -s","addpay":"","append":"","useSpawn":"false","timer":"","winHide":false,"oldrc":false,"name":"Get OS Name & last reboot","x":1450,"y":1140,"wires":[["5f6080b8.724c8"],[],[]]},{"id":"b2eada78.c69358","type":"exec","z":"32bc1133.9bf706","command":"ls -lact --full-time /etc |awk 'END {print $6,$7,$8}'","addpay":"","append":"","useSpawn":"false","timer":"","winHide":false,"oldrc":false,"name":"OS Install Dt","x":1400,"y":1200,"wires":[["dde4c354.5ba12"],[],[]]},{"id":"dde4c354.5ba12","type":"function","z":"32bc1133.9bf706","name":"","func":"msg.var = \"INFO\"\nmsg.prop = \"system.server\"\nmsg.val = {}\n\nmsg.val.os_installed = new Date(msg.payload.trim())\n\nreturn msg\n","outputs":1,"timeout":"","noerr":0,"initialize":"","finalize":"","libs":[],"x":1625,"y":1200,"wires":[["271ea0173ca6f4b5"]],"l":false},{"id":"cf70194f.ca8478","type":"function","z":"32bc1133.9bf706","name":"","func":"msg.var = \"INFO\"\nmsg.prop = \"system.nodered.last_restart\"\nmsg.val = msg.payload.trim().replace('+00:00','.000Z')\n\nreturn msg\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1625,"y":1260,"wires":[["f402b50c783046a2"]],"l":false},{"id":"174f9b34.08c585","type":"exec","z":"32bc1133.9bf706","command":"sudo systemctl show nodered | grep -oP 'ExecMainStartTimestamp=\\K.*' | xargs -0 date -Iseconds -u -d","addpay":"","append":"","useSpawn":"false","timer":"","winHide":false,"oldrc":false,"name":"Node-RED restarted last?","x":1440,"y":1260,"wires":[["cf70194f.ca8478"],[],[]]},{"id":"a81d73e6.f2b48","type":"exec","z":"32bc1133.9bf706","command":"npm list -g node-red --depth=0 | grep -oP 'node-red@\\K[^@\\s]+'","addpay":"","append":"","useSpawn":"false","timer":"","winHide":false,"oldrc":false,"name":"Node-RED current version","x":1450,"y":1320,"wires":[["b5575ac.eb4c1a8"],[],[]]},{"id":"b5575ac.eb4c1a8","type":"function","z":"32bc1133.9bf706","name":"","func":"msg.var = \"INFO\"\nmsg.prop = \"system.nodered.version\"\nmsg.val = msg.payload.trim()\n\nreturn msg\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1625,"y":1320,"wires":[["91be16884fba7d7b"]],"l":false},{"id":"35352753.1c63d8","type":"exec","z":"32bc1133.9bf706","command":"node --version","addpay":"","append":"","useSpawn":"false","timer":"","winHide":false,"oldrc":false,"name":"Node.js current version","x":1440,"y":1380,"wires":[["2e54abd3.f445a4"],[],[]]},{"id":"2e54abd3.f445a4","type":"function","z":"32bc1133.9bf706","name":"","func":"msg.var = \"INFO\"\nmsg.prop = \"system.node.version\"\nmsg.val = msg.payload.trim()\n\nreturn msg\n","outputs":1,"timeout":"","noerr":0,"initialize":"","finalize":"","libs":[],"x":1625,"y":1380,"wires":[["0d1258e5da087cbb"]],"l":false},{"id":"cd99fc7f.3ed21","type":"function","z":"32bc1133.9bf706","name":"","func":"msg.var = \"INFO\"\nmsg.prop = \"system.node.npm_version\"\nmsg.val = msg.payload.trim()\n\nreturn msg\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1625,"y":1440,"wires":[["0719a207ec68c560"]],"l":false},{"id":"83f3c36b.fcf6","type":"exec","z":"32bc1133.9bf706","command":"npm --version","addpay":"","append":"","useSpawn":"false","timer":"","winHide":false,"oldrc":false,"name":"npm current version","x":1430,"y":1440,"wires":[["cd99fc7f.3ed21"],[],[]]},{"id":"6837697c8f850add","type":"debug","z":"32bc1133.9bf706","name":"debug 76","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":1740,"y":1130,"wires":[]},{"id":"271ea0173ca6f4b5","type":"debug","z":"32bc1133.9bf706","name":"debug 77","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":1750,"y":1200,"wires":[]},{"id":"f402b50c783046a2","type":"debug","z":"32bc1133.9bf706","name":"debug 78","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":1730,"y":1260,"wires":[]},{"id":"91be16884fba7d7b","type":"debug","z":"32bc1133.9bf706","name":"debug 79","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":1750,"y":1330,"wires":[]},{"id":"0d1258e5da087cbb","type":"debug","z":"32bc1133.9bf706","name":"debug 80","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":1750,"y":1380,"wires":[]},{"id":"0719a207ec68c560","type":"debug","z":"32bc1133.9bf706","name":"debug 81","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":1750,"y":1440,"wires":[]}]

It should work for a "standard" NR install, and includes the following changes

Get OS Name & last reboot
In function node setup-tab add os imported as os, in on message-tab remove references to require.

Node-RED restarted last?
Change the service name to nodered -

sudo systemctl show nodered | grep -oP 'ExecMainStartTimestamp=\K.*' | xargs -0 date -Iseconds -u -d

Node-RED current version
Official install script is a global install, which can be found using a slightly different command. Change the command in the exec node to -

npm list -g node-red --depth=0 | grep -oP 'node-red@\K[^@\s]+'

NR Diagnostics
Not sure if this is a custom endpoint, but doesn't work for me ?

Function 4
The flow is missing all the other nodes :wink:

There is only 1 part that is custom that I'd forgotten about. In the first fn node, remove the 2 lines that refer to require and add os as a module in the setup of that node. I wrote that long before adding modules to function nodes was possible. :slight_smile:

Everything else should work on anyone's Node-RED instance.

Sorry, should have said that the OS commands mostly assume that you are on Linux. But they wouldn't be hard to adjust for other OS's.

Running the slightly modified flow.

Working here.

I'll put it on the RasPi ASAP.
Though the one error is of slight concern.

Here is a small tweak I did which MAY be better for people.

But I can't get the node-red last restarted value to work.
(on the Ubuntu machine at least)

[{"id":"53755bb120c6ceb8","type":"exec","z":"65c9b63cb09879a0","command":"npm list -g node-red --depth=0 | grep -oP 'node-red@\\K[^@\\s]+'","addpay":"","append":"","useSpawn":"false","timer":"","winHide":false,"oldrc":false,"name":"Node-RED current version","x":4250,"y":2930,"wires":[["8f396a40ab38b367"],[],[]]},{"id":"6c3a701d3d95f84e","type":"inject","z":"65c9b63cb09879a0","name":"","props":[{"p":"topic","vt":"str"}],"repeat":"21600","crontab":"","once":true,"onceDelay":0.1,"topic":"OS Info","x":4005,"y":2750,"wires":[["2e52422215f0773d","694b04458be823a6","83eeb3be4aef3f98","53755bb120c6ceb8","7868cb709aa70716","38e0a6a4ddb70943"]],"l":false},{"id":"8f396a40ab38b367","type":"function","z":"65c9b63cb09879a0","name":"","func":"msg.var = \"INFO\"\nmsg.prop = \"system.nodered.version\"\nmsg.val = msg.payload.trim()\n\nreturn msg\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":4425,"y":2930,"wires":[["4ed19bb198825e9d","e18e5f89925e88ff"]],"l":false},{"id":"2e52422215f0773d","type":"exec","z":"65c9b63cb09879a0","command":"cat /etc/os-release | grep -oP '^PRETTY_NAME=\\\"\\K.*?(?=\")'  && uptime -s","addpay":"","append":"","useSpawn":"false","timer":"","winHide":false,"oldrc":false,"name":"Get OS Name & last reboot","x":4250,"y":2750,"wires":[["182d97ee5516dc5f"],[],[]]},{"id":"694b04458be823a6","type":"exec","z":"65c9b63cb09879a0","command":"ls -lact --full-time /etc |awk 'END {print $6,$7,$8}'","addpay":"","append":"","useSpawn":"false","timer":"","winHide":false,"oldrc":false,"name":"OS Install Dt","x":4200,"y":2810,"wires":[["d48fc1f140bc6520"],[],[]]},{"id":"83eeb3be4aef3f98","type":"exec","z":"65c9b63cb09879a0","command":"sudo systemctl show nodered | grep -oP 'ExecMainStartTimestamp=\\K.*' | xargs -0 date -Iseconds -u -d","addpay":"","append":"","useSpawn":"false","timer":"","winHide":false,"oldrc":false,"name":"Node-RED restarted last?","x":4240,"y":2870,"wires":[["9d47ce5a7a04c537"],[],[]]},{"id":"7868cb709aa70716","type":"exec","z":"65c9b63cb09879a0","command":"node --version","addpay":"","append":"","useSpawn":"false","timer":"","winHide":false,"oldrc":false,"name":"Node.js current version","x":4240,"y":2990,"wires":[["62f398e8c0a20318"],[],[]]},{"id":"38e0a6a4ddb70943","type":"exec","z":"65c9b63cb09879a0","command":"npm --version","addpay":"","append":"","useSpawn":"false","timer":"","winHide":false,"oldrc":false,"name":"npm current version","x":4230,"y":3050,"wires":[["a8fe80bf444786b7"],[],[]]},{"id":"4ed19bb198825e9d","type":"debug","z":"65c9b63cb09879a0","name":"NR version","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":4710,"y":2930,"wires":[]},{"id":"e18e5f89925e88ff","type":"template","z":"65c9b63cb09879a0","name":"","field":"payload","fieldType":"msg","format":"handlebars","syntax":"mustache","template":"N/R version {{payload}} ","output":"str","x":4520,"y":2960,"wires":[["47cf93bf3221b468"]]},{"id":"182d97ee5516dc5f","type":"function","z":"65c9b63cb09879a0","name":"","func":"const pay = msg.payload.split('\\n')\n\nmsg.var = \"INFO\"\nmsg.prop = \"system.server\"\nconst server = {}\n\nserver.hostname = os.hostname()\nserver.type = os.type()\nserver.os = pay[0]\nserver.last_reboot = new Date(pay[1])\nserver.release = os.release()\nserver.version = os.version()\n//server.platform = os.platform()\nserver.arch = os.arch()\nserver.endianness = os.endianness()\nserver.cpu = os.cpus()[0].model\nserver.cores = os.cpus().length\nserver.totalmem = Number.parseFloat( os.totalmem()/1073741824 ).toFixed(1) // GB\n\n// server.freemem = os.freemem()\n// server.loadavg = os.loadavg()\n// server.networkInterfaces = os.networkInterfaces()\n\nmsg.val = server //{}\n//msg.val.system = system\n\nreturn msg\n\n// cat /etc/os-release | grep -oP '^PRETTY_NAME=\\\"\\K.*?(?=\")'\n// lsb_release -a\n//     Description:    Debian GNU/Linux 10 (buster)","outputs":1,"timeout":"","noerr":0,"initialize":"","finalize":"","libs":[{"var":"os","module":"os"}],"x":4425,"y":2750,"wires":[["6762a535df84d344","280c69c222ab28db"]],"l":false},{"id":"d48fc1f140bc6520","type":"function","z":"65c9b63cb09879a0","name":"","func":"msg.var = \"INFO\"\nmsg.prop = \"system.server\"\nmsg.val = {}\n\nmsg.val.os_installed = new Date(msg.payload.trim())\n\nreturn msg\n","outputs":1,"timeout":"","noerr":0,"initialize":"","finalize":"","libs":[],"x":4425,"y":2810,"wires":[["811063316450194e","69d7eb987fdd466c"]],"l":false},{"id":"9d47ce5a7a04c537","type":"function","z":"65c9b63cb09879a0","name":"","func":"msg.var = \"INFO\"\nmsg.prop = \"system.nodered.last_restart\"\nmsg.val = msg.payload.trim().replace('+00:00','.000Z')\n\nreturn msg\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":4425,"y":2870,"wires":[["cf645fef91d33b11","b48636e653632b32"]],"l":false},{"id":"62f398e8c0a20318","type":"function","z":"65c9b63cb09879a0","name":"","func":"msg.var = \"INFO\"\nmsg.prop = \"system.node.version\"\nmsg.val = msg.payload.trim()\n\nreturn msg\n","outputs":1,"timeout":"","noerr":0,"initialize":"","finalize":"","libs":[],"x":4425,"y":2990,"wires":[["4c7951a31bd5f922","bf40aeba4bc91e3a"]],"l":false},{"id":"a8fe80bf444786b7","type":"function","z":"65c9b63cb09879a0","name":"","func":"msg.var = \"INFO\"\nmsg.prop = \"system.node.npm_version\"\nmsg.val = msg.payload.trim()\n\nreturn msg\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":4425,"y":3050,"wires":[["2b7c28dcf9d1aae4","4fdc0671babf3c4b"]],"l":false},{"id":"47cf93bf3221b468","type":"join","z":"65c9b63cb09879a0","name":"","mode":"custom","build":"string","property":"payload","propertyType":"msg","key":"topic","joiner":"\\n","joinerType":"str","useparts":false,"accumulate":false,"timeout":"","count":"5","reduceRight":false,"reduceExp":"","reduceInit":"","reduceInitType":"","reduceFixup":"","x":4720,"y":3140,"wires":[["ac61c2633ef7e832"]]},{"id":"6762a535df84d344","type":"debug","z":"65c9b63cb09879a0","name":"O/S name and last reboot","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":4750,"y":2750,"wires":[]},{"id":"280c69c222ab28db","type":"template","z":"65c9b63cb09879a0","name":"","field":"payload","fieldType":"msg","format":"handlebars","syntax":"mustache","template":"O/S and last reboot {{payload}} ","output":"str","x":4520,"y":2780,"wires":[["47cf93bf3221b468"]]},{"id":"811063316450194e","type":"debug","z":"65c9b63cb09879a0","name":"debug 77","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":4700,"y":2810,"wires":[]},{"id":"69d7eb987fdd466c","type":"template","z":"65c9b63cb09879a0","name":"","field":"payload","fieldType":"msg","format":"handlebars","syntax":"mustache","template":"O/S install DT {{payload}} ","output":"str","x":4520,"y":2840,"wires":[["47cf93bf3221b468"]]},{"id":"cf645fef91d33b11","type":"debug","z":"65c9b63cb09879a0","name":"NR last restarted","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":4730,"y":2870,"wires":[]},{"id":"b48636e653632b32","type":"template","z":"65c9b63cb09879a0","name":"","field":"payload","fieldType":"msg","format":"handlebars","syntax":"mustache","template":"This is the payload: {{payload}} !","output":"str","x":4520,"y":2900,"wires":[[]]},{"id":"4c7951a31bd5f922","type":"debug","z":"65c9b63cb09879a0","name":"Node.js version","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":4720,"y":2990,"wires":[]},{"id":"bf40aeba4bc91e3a","type":"template","z":"65c9b63cb09879a0","name":"","field":"payload","fieldType":"msg","format":"handlebars","syntax":"mustache","template":"Node.js version {{payload}} ","output":"str","x":4520,"y":3020,"wires":[["47cf93bf3221b468"]]},{"id":"2b7c28dcf9d1aae4","type":"debug","z":"65c9b63cb09879a0","name":"NPM version","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":4710,"y":3050,"wires":[]},{"id":"4fdc0671babf3c4b","type":"template","z":"65c9b63cb09879a0","name":"","field":"payload","fieldType":"msg","format":"handlebars","syntax":"mustache","template":"NPM version {{payload}} ","output":"str","x":4520,"y":3080,"wires":[["47cf93bf3221b468"]]},{"id":"ac61c2633ef7e832","type":"debug","z":"65c9b63cb09879a0","name":"All data","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":4900,"y":3140,"wires":[]}]

With this, you get one message which you can copy/paste to the forum.

Well there is a problem that the sudo command needs the password.

Sorry.

AND...

 sudo systemctl show nodered | grep -oP 'ExecMainStartTimestamp=\K.*' | xargs -0 date -Iseconds -u -d
[sudo] password for me: 
date: invalid date ‘Wed 2025-06-11 07:40:14 AEST\n’

invalid date probably won't help.

Just to check:

(with either/both)

This flow is seemingly ONLY for machine identification.

NOTHING to do with catching errors or the like.

Just so it is clear in my mind and there is no mistakes.

This code works on my UBUNTU NUC

[{"id":"d02cb65efee301f1","type":"exec","z":"65c9b63cb09879a0","command":"systemctl show nodered | grep ^ExecMainStartTimestamp= | cut -d= -f2-","addpay":"","append":"","useSpawn":"false","timer":"","winHide":false,"oldrc":false,"name":"Node-RED restarted last?","x":4260,"y":3400,"wires":[["0311db730a002792"],[],[]]},{"id":"e5c2ee066e9fbfc6","type":"inject","z":"65c9b63cb09879a0","name":"","props":[{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"OS Info","x":4025,"y":3280,"wires":[["f8c36499d7f2a52c","0c9a36f1d1d24c26","d02cb65efee301f1","c1037cfa5fd5726a","4e3b82d1a7ea356f","b7c14e12e20a0f94"]],"l":false},{"id":"0311db730a002792","type":"function","z":"65c9b63cb09879a0","name":"","func":"msg.var = \"INFO\"\nmsg.prop = \"system.nodered.last_restart\"\nmsg.val = msg.payload.trim().replace('+00:00','.000Z')\n\nreturn msg\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":4445,"y":3400,"wires":[["917143b7247bfc23","4405895f9ac5fae2"]],"l":false},{"id":"f8c36499d7f2a52c","type":"exec","z":"65c9b63cb09879a0","command":"cat /etc/os-release | grep -oP '^PRETTY_NAME=\\\"\\K.*?(?=\")'  && uptime -s","addpay":"","append":"","useSpawn":"false","timer":"","winHide":false,"oldrc":false,"name":"Get OS Name & last reboot","x":4270,"y":3280,"wires":[["08df6dd7f4c7475b"],[],[]]},{"id":"0c9a36f1d1d24c26","type":"exec","z":"65c9b63cb09879a0","command":"sudo tune2fs -l $(df / | tail -1 | awk '{print $1}') | grep 'Filesystem created:' | cut -d: -f2- | xargs","addpay":"","append":"","useSpawn":"false","timer":"","winHide":false,"oldrc":false,"name":"OS Install Dt","x":4220,"y":3340,"wires":[["d5835190e53e665f"],[],[]]},{"id":"c1037cfa5fd5726a","type":"exec","z":"65c9b63cb09879a0","command":"npm list -g node-red --depth=0 | grep -oP 'node-red@\\K[^@\\s]+'","addpay":"","append":"","useSpawn":"false","timer":"","winHide":false,"oldrc":false,"name":"Node-RED current version","x":4270,"y":3460,"wires":[["32fd3e7362c8d1f1"],[],[]]},{"id":"4e3b82d1a7ea356f","type":"exec","z":"65c9b63cb09879a0","command":"node --version","addpay":"","append":"","useSpawn":"false","timer":"","winHide":false,"oldrc":false,"name":"Node.js current version","x":4260,"y":3520,"wires":[["ee81681b41d04e27"],[],[]]},{"id":"b7c14e12e20a0f94","type":"exec","z":"65c9b63cb09879a0","command":"npm --version","addpay":"","append":"","useSpawn":"false","timer":"","winHide":false,"oldrc":false,"name":"npm current version","x":4250,"y":3580,"wires":[["a7e14e47fe84720b"],[],[]]},{"id":"917143b7247bfc23","type":"debug","z":"65c9b63cb09879a0","name":"NR last restarted","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":4750,"y":3400,"wires":[]},{"id":"4405895f9ac5fae2","type":"template","z":"65c9b63cb09879a0","name":"","field":"payload","fieldType":"msg","format":"handlebars","syntax":"mustache","template":"Node-red last started {{payload}} ","output":"str","x":4540,"y":3430,"wires":[["9104b0360038ccb0"]]},{"id":"08df6dd7f4c7475b","type":"function","z":"65c9b63cb09879a0","name":"","func":"const pay = msg.payload.split('\\n')\n\nmsg.var = \"INFO\"\nmsg.prop = \"system.server\"\nconst server = {}\n\nserver.hostname = os.hostname()\nserver.type = os.type()\nserver.os = pay[0]\nserver.last_reboot = new Date(pay[1])\nserver.release = os.release()\nserver.version = os.version()\n//server.platform = os.platform()\nserver.arch = os.arch()\nserver.endianness = os.endianness()\nserver.cpu = os.cpus()[0].model\nserver.cores = os.cpus().length\nserver.totalmem = Number.parseFloat( os.totalmem()/1073741824 ).toFixed(1) // GB\n\n// server.freemem = os.freemem()\n// server.loadavg = os.loadavg()\n// server.networkInterfaces = os.networkInterfaces()\n\nmsg.val = server //{}\n//msg.val.system = system\n\nreturn msg\n\n// cat /etc/os-release | grep -oP '^PRETTY_NAME=\\\"\\K.*?(?=\")'\n// lsb_release -a\n//     Description:    Debian GNU/Linux 10 (buster)","outputs":1,"timeout":"","noerr":0,"initialize":"","finalize":"","libs":[{"var":"os","module":"os"}],"x":4445,"y":3280,"wires":[["e369c7b8dfd5743d","52e7a1881b55df36"]],"l":false},{"id":"d5835190e53e665f","type":"function","z":"65c9b63cb09879a0","name":"","func":"msg.var = \"INFO\"\nmsg.prop = \"system.server\"\nmsg.val = {}\n\nmsg.val.os_installed = msg.payload.trim()\n\nreturn msg\n","outputs":1,"timeout":"","noerr":0,"initialize":"","finalize":"","libs":[],"x":4445,"y":3340,"wires":[["834e2348995df30e","65218ece78508079"]],"l":false},{"id":"32fd3e7362c8d1f1","type":"function","z":"65c9b63cb09879a0","name":"","func":"msg.var = \"INFO\"\nmsg.prop = \"system.nodered.version\"\nmsg.val = msg.payload.trim()\n\nreturn msg\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":4445,"y":3460,"wires":[["8705e093b67058e2","ee984aea418f2c16"]],"l":false},{"id":"ee81681b41d04e27","type":"function","z":"65c9b63cb09879a0","name":"","func":"msg.var = \"INFO\"\nmsg.prop = \"system.node.version\"\nmsg.val = msg.payload.trim()\n\nreturn msg\n","outputs":1,"timeout":"","noerr":0,"initialize":"","finalize":"","libs":[],"x":4445,"y":3520,"wires":[["c9dc226153c72825","38288951667915eb"]],"l":false},{"id":"a7e14e47fe84720b","type":"function","z":"65c9b63cb09879a0","name":"","func":"msg.var = \"INFO\"\nmsg.prop = \"system.node.npm_version\"\nmsg.val = msg.payload.trim()\n\nreturn msg\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":4445,"y":3580,"wires":[["c6caa9a0f395e05e","9cb31a2aecd56a1c"]],"l":false},{"id":"9104b0360038ccb0","type":"join","z":"65c9b63cb09879a0","name":"","mode":"custom","build":"string","property":"payload","propertyType":"msg","key":"topic","joiner":"\\n","joinerType":"str","useparts":false,"accumulate":false,"timeout":"","count":"6","reduceRight":false,"reduceExp":"","reduceInit":"","reduceInitType":"","reduceFixup":"","x":4740,"y":3670,"wires":[["e776e02060c8757f"]]},{"id":"e369c7b8dfd5743d","type":"debug","z":"65c9b63cb09879a0","name":"O/S name and last reboot","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":4770,"y":3280,"wires":[]},{"id":"52e7a1881b55df36","type":"template","z":"65c9b63cb09879a0","name":"","field":"payload","fieldType":"msg","format":"handlebars","syntax":"mustache","template":"O/S and last reboot {{payload}} ","output":"str","x":4540,"y":3310,"wires":[["9104b0360038ccb0"]]},{"id":"834e2348995df30e","type":"debug","z":"65c9b63cb09879a0","name":"debug 77","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":4720,"y":3340,"wires":[]},{"id":"65218ece78508079","type":"template","z":"65c9b63cb09879a0","name":"","field":"payload","fieldType":"msg","format":"handlebars","syntax":"mustache","template":"O/S install DT {{payload}} ","output":"str","x":4540,"y":3370,"wires":[["9104b0360038ccb0"]]},{"id":"8705e093b67058e2","type":"debug","z":"65c9b63cb09879a0","name":"NR version","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":4730,"y":3460,"wires":[]},{"id":"ee984aea418f2c16","type":"template","z":"65c9b63cb09879a0","name":"","field":"payload","fieldType":"msg","format":"handlebars","syntax":"mustache","template":"N/R version {{payload}} ","output":"str","x":4540,"y":3490,"wires":[["9104b0360038ccb0"]]},{"id":"c9dc226153c72825","type":"debug","z":"65c9b63cb09879a0","name":"Node.js version","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":4740,"y":3520,"wires":[]},{"id":"38288951667915eb","type":"template","z":"65c9b63cb09879a0","name":"","field":"payload","fieldType":"msg","format":"handlebars","syntax":"mustache","template":"Node.js version {{payload}} ","output":"str","x":4540,"y":3550,"wires":[["9104b0360038ccb0"]]},{"id":"c6caa9a0f395e05e","type":"debug","z":"65c9b63cb09879a0","name":"NPM version","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":4730,"y":3580,"wires":[]},{"id":"9cb31a2aecd56a1c","type":"template","z":"65c9b63cb09879a0","name":"","field":"payload","fieldType":"msg","format":"handlebars","syntax":"mustache","template":"NPM version {{payload}} ","output":"str","x":4540,"y":3610,"wires":[["9104b0360038ccb0"]]},{"id":"e776e02060c8757f","type":"debug","z":"65c9b63cb09879a0","name":"All data","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":4920,"y":3670,"wires":[]}]

And working on all RasPi machines too.

Yeah it's just an old flow Julian posted to get some system info.
Several things didn't work on my Pi running Bookworm, hence the modified flow.

It seems there are some differences with Ubuntu and Debian also.

Give this a try on Ubuntu

[{"id":"53755bb120c6ceb8","type":"exec","z":"32bc1133.9bf706","command":"npm list -g node-red --depth=0 | grep -oP 'node-red@\\K[^@\\s]+'","addpay":"","append":"","useSpawn":"false","timer":"","winHide":false,"oldrc":false,"name":"Node-RED current version","x":1290,"y":2110,"wires":[["8f396a40ab38b367"],[],[]]},{"id":"6c3a701d3d95f84e","type":"inject","z":"32bc1133.9bf706","name":"","props":[{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"OS Info","x":1045,"y":1930,"wires":[["2e52422215f0773d","694b04458be823a6","83eeb3be4aef3f98","53755bb120c6ceb8","7868cb709aa70716","38e0a6a4ddb70943"]],"l":false},{"id":"8f396a40ab38b367","type":"function","z":"32bc1133.9bf706","name":"","func":"msg.var = \"INFO\"\nmsg.prop = \"system.nodered.version\"\nmsg.val = msg.payload.trim()\n\nreturn msg\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1465,"y":2110,"wires":[["4ed19bb198825e9d","e18e5f89925e88ff"]],"l":false},{"id":"2e52422215f0773d","type":"exec","z":"32bc1133.9bf706","command":"cat /etc/os-release | grep -oP '^PRETTY_NAME=\\\"\\K.*?(?=\")'  && uptime -s","addpay":"","append":"","useSpawn":"false","timer":"","winHide":false,"oldrc":false,"name":"Get OS Name & last reboot","x":1290,"y":1930,"wires":[["182d97ee5516dc5f"],[],[]]},{"id":"694b04458be823a6","type":"exec","z":"32bc1133.9bf706","command":"sudo tune2fs -l $(df / | tail -1 | awk '{print $1}') | grep 'Filesystem created:' | cut -d: -f2- | xargs","addpay":"","append":"","useSpawn":"false","timer":"","winHide":false,"oldrc":false,"name":"OS Install Dt","x":1240,"y":1990,"wires":[["d48fc1f140bc6520"],[],[]]},{"id":"83eeb3be4aef3f98","type":"exec","z":"32bc1133.9bf706","command":"systemctl show nodered --property=ExecMainStartTimestamp --value | grep -v '^$\\|^0$' | xargs -r -I {} date -Iseconds -u -d \"{}\"","addpay":"","append":"","useSpawn":"false","timer":"","winHide":false,"oldrc":false,"name":"Node-RED restarted last?","x":1280,"y":2050,"wires":[["9d47ce5a7a04c537"],[],[]]},{"id":"7868cb709aa70716","type":"exec","z":"32bc1133.9bf706","command":"node --version","addpay":"","append":"","useSpawn":"false","timer":"","winHide":false,"oldrc":false,"name":"Node.js current version","x":1280,"y":2170,"wires":[["62f398e8c0a20318"],[],[]]},{"id":"38e0a6a4ddb70943","type":"exec","z":"32bc1133.9bf706","command":"npm --version","addpay":"","append":"","useSpawn":"false","timer":"","winHide":false,"oldrc":false,"name":"npm current version","x":1270,"y":2230,"wires":[["a8fe80bf444786b7"],[],[]]},{"id":"4ed19bb198825e9d","type":"debug","z":"32bc1133.9bf706","name":"NR version","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":1750,"y":2110,"wires":[]},{"id":"e18e5f89925e88ff","type":"template","z":"32bc1133.9bf706","name":"","field":"payload","fieldType":"msg","format":"handlebars","syntax":"mustache","template":"N/R version {{payload}} ","output":"str","x":1560,"y":2140,"wires":[["47cf93bf3221b468"]]},{"id":"182d97ee5516dc5f","type":"function","z":"32bc1133.9bf706","name":"","func":"const pay = msg.payload.split('\\n')\n\nmsg.var = \"INFO\"\nmsg.prop = \"system.server\"\nconst server = {}\n\nserver.hostname = os.hostname()\nserver.type = os.type()\nserver.os = pay[0]\nserver.last_reboot = new Date(pay[1])\nserver.release = os.release()\nserver.version = os.version()\n//server.platform = os.platform()\nserver.arch = os.arch()\nserver.endianness = os.endianness()\nserver.cpu = os.cpus()[0].model\nserver.cores = os.cpus().length\nserver.totalmem = Number.parseFloat( os.totalmem()/1073741824 ).toFixed(1) // GB\n\n// server.freemem = os.freemem()\n// server.loadavg = os.loadavg()\n// server.networkInterfaces = os.networkInterfaces()\n\nmsg.val = server //{}\n//msg.val.system = system\n\nreturn msg\n\n// cat /etc/os-release | grep -oP '^PRETTY_NAME=\\\"\\K.*?(?=\")'\n// lsb_release -a\n//     Description:    Debian GNU/Linux 10 (buster)","outputs":1,"timeout":"","noerr":0,"initialize":"","finalize":"","libs":[{"var":"os","module":"os"}],"x":1465,"y":1930,"wires":[["6762a535df84d344","280c69c222ab28db"]],"l":false},{"id":"d48fc1f140bc6520","type":"function","z":"32bc1133.9bf706","name":"","func":"msg.var = \"INFO\"\nmsg.prop = \"system.server\"\nmsg.val = {}\n\nmsg.val.os_installed = msg.payload.trim()\n\nreturn msg\n","outputs":1,"timeout":"","noerr":0,"initialize":"","finalize":"","libs":[],"x":1465,"y":1990,"wires":[["811063316450194e","69d7eb987fdd466c"]],"l":false},{"id":"9d47ce5a7a04c537","type":"function","z":"32bc1133.9bf706","name":"","func":"msg.var = \"INFO\"\nmsg.prop = \"system.nodered.last_restart\"\nmsg.val = msg.payload.trim().replace('+00:00','.000Z')\n\nreturn msg\n","outputs":1,"timeout":"","noerr":0,"initialize":"","finalize":"","libs":[],"x":1465,"y":2050,"wires":[["cf645fef91d33b11","b48636e653632b32"]],"l":false},{"id":"62f398e8c0a20318","type":"function","z":"32bc1133.9bf706","name":"","func":"msg.var = \"INFO\"\nmsg.prop = \"system.node.version\"\nmsg.val = msg.payload.trim()\n\nreturn msg\n","outputs":1,"timeout":"","noerr":0,"initialize":"","finalize":"","libs":[],"x":1465,"y":2170,"wires":[["4c7951a31bd5f922","bf40aeba4bc91e3a"]],"l":false},{"id":"a8fe80bf444786b7","type":"function","z":"32bc1133.9bf706","name":"","func":"msg.var = \"INFO\"\nmsg.prop = \"system.node.npm_version\"\nmsg.val = msg.payload.trim()\n\nreturn msg\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1465,"y":2230,"wires":[["2b7c28dcf9d1aae4","4fdc0671babf3c4b"]],"l":false},{"id":"47cf93bf3221b468","type":"join","z":"32bc1133.9bf706","name":"","mode":"custom","build":"string","property":"payload","propertyType":"msg","key":"topic","joiner":"\\n","joinerType":"str","useparts":false,"accumulate":false,"timeout":"","count":"6","reduceRight":false,"reduceExp":"","reduceInit":"","reduceInitType":"","reduceFixup":"","x":1760,"y":2320,"wires":[["ac61c2633ef7e832"]]},{"id":"6762a535df84d344","type":"debug","z":"32bc1133.9bf706","name":"O/S name and last reboot","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":1790,"y":1930,"wires":[]},{"id":"280c69c222ab28db","type":"template","z":"32bc1133.9bf706","name":"","field":"payload","fieldType":"msg","format":"handlebars","syntax":"mustache","template":"O/S and last reboot {{payload}} ","output":"str","x":1560,"y":1960,"wires":[["47cf93bf3221b468"]]},{"id":"811063316450194e","type":"debug","z":"32bc1133.9bf706","name":"debug 77","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":1740,"y":1990,"wires":[]},{"id":"69d7eb987fdd466c","type":"template","z":"32bc1133.9bf706","name":"","field":"payload","fieldType":"msg","format":"handlebars","syntax":"mustache","template":"O/S install DT {{payload}} ","output":"str","x":1560,"y":2020,"wires":[["47cf93bf3221b468"]]},{"id":"cf645fef91d33b11","type":"debug","z":"32bc1133.9bf706","name":"NR last restarted","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":1770,"y":2050,"wires":[]},{"id":"b48636e653632b32","type":"template","z":"32bc1133.9bf706","name":"","field":"payload","fieldType":"msg","format":"handlebars","syntax":"mustache","template":"Node-RED Started: {{payload}}","output":"str","x":1560,"y":2080,"wires":[["47cf93bf3221b468"]]},{"id":"4c7951a31bd5f922","type":"debug","z":"32bc1133.9bf706","name":"Node.js version","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":1760,"y":2170,"wires":[]},{"id":"bf40aeba4bc91e3a","type":"template","z":"32bc1133.9bf706","name":"","field":"payload","fieldType":"msg","format":"handlebars","syntax":"mustache","template":"Node.js version {{payload}} ","output":"str","x":1560,"y":2200,"wires":[["47cf93bf3221b468"]]},{"id":"2b7c28dcf9d1aae4","type":"debug","z":"32bc1133.9bf706","name":"NPM version","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":1750,"y":2230,"wires":[]},{"id":"4fdc0671babf3c4b","type":"template","z":"32bc1133.9bf706","name":"","field":"payload","fieldType":"msg","format":"handlebars","syntax":"mustache","template":"NPM version {{payload}} ","output":"str","x":1560,"y":2260,"wires":[["47cf93bf3221b468"]]},{"id":"ac61c2633ef7e832","type":"debug","z":"32bc1133.9bf706","name":"All data","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":1940,"y":2320,"wires":[]}]