Node Red crash Flow dissapeared please help

Hi,

I have a ubuntu virtual machine running node-red v1.0.3 (a local install) I have been working on a flow for 4 months now. last night the node-red web editor crashed just as I clicked deploy after i restarted the virtual machine I could no longer find my flow.

Stupidly I have not backed the flow up, I read online there should be a backup of the flow in the .Node-Red directory in the home directory but I am unable to find this hidden folder. I also read that this is usually caused by the machine name changing I can confirm this has not happened in my case.

I am almost out of ideas if anybody has any hints they would be very much appreciated.

What do you see when you start node red in a terminal. Note, do not click deploy as that may overwrite any backup flow file that there is. The startup log should tell you where the .node-red folder is.

Hi Colin, thank you for your reply. I have not clicked deploy since this has happened. node-red is installed as a snap and starts automatically.

I have just attempted to stop and start the service from the terminal to answer your question but it does not seem to recognise any of the commands, please see the commands I have attempted to use below .

node-red
sudo node-red stop
sudo node-red start

thanks

update: I have just used the locate function in the terminal

sudo locate flows.json

result:
/root/snap/node-red/527/.flow.json.backup
/root/snap/node-red/527/flow.json
/root/snap/node-red/533/.flow.json.backup

are these the back up's i need? if so it appears they are located inside the root user which I do not currently have a password for.

Update:

Thank you Colin for the help I managed to locate the old flows using the locate command in the terminal.

for anyone else having this issue install locate using sudo apt-get install locate then type sudo locate flows.json.backup if your search gives you results go to the directory where the files are found make a copy of the flow backup file. open it in a text editor copy all contents, open node-red web editor open menu and import.

my issue was finding the backup file this was due to all the back up's been located in the root folder path /root/snap/node-red/

I hope this helps anyone facing the same issue.

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