As pi:
pi@raspberrypi:~ cd /home/pi/.node-red
pi@raspberrypi:~/.node-red ls
flows_raspberrypi_cred.json lib package.json
flows_raspberrypi.json node_modules settings.js
pi@raspberrypi:~/.node-red $
As root:
root@raspberrypi:~# cd /home/pi/.node-red
root@raspberrypi:/home/pi/.node-red# ls
flows_raspberrypi_cred.json lib package.json
flows_raspberrypi.json node_modules settings.js
root@raspberrypi:/home/pi/.node-red#
From your paste when you logged in as root:
Do you see it is picking up a different flows file?
There should be no need to run Node-RED as root or using the sudo command. It will cause you more problems.
I suggest you look at the size of the files in the two .node-red directories
/root/.node-red
and
/pi/.node-red
to work out which one you were using with your old flows.
could you please show me how to see the size? with command or explorer ?
there is size in file flows_raspberrypi.json
and i check it with nano command, it turns out all of my flow. but how to put it into node-red again ?
i tried to copy the clipboard but it doesn't work
so what happens if you start node-RED using the correct command as user pi?
i have try that but after i copied the clipboard through the explorer file and paste it into the node-red. and my flow coming back.
the result is same between pi or root when i run the start command
thank you for helping me solved the problem
Best Response. This should be highlighted for newbies ( like me ). Was pulling my hair out...