Problem moving Flows between a Pi & Winbox

Hi All,

I've got N-R on my pi but am actively building on my Winbox. So far, I've "saved" a half-dozen flows/nodes while on the Winbox, but when I try and import one, there are only two showing and both if those are on the pi. So, where are the files saved on the Winbox? I'm guessing I need to eventually transfer them to the pi, but gotta find them first...

Russ

What do you mean by saving flows/nodes?

I don't fully understand your description of the problem... but
Are you trying to move some flows from the Winbox to a Pi?

If so, are you exporting the flows from the Winbox, and then importing them into the pi, using the node-RED interface?

PS - a 'flow' is a collection of nodes, whilst a 'node' is just a single node.

Export -> Library. When I click on "Library", it opens a folder called local. Both boxes have the same two (older) files so I must have, at one time, been able to do this.

So this week:

I've exported some nodes on the Winbox. I think.

I'm simply trying to find where these "exports" went. They are not on my Winbox and I don't have enough "Raspbian" knowledge to know how to find them - if - they ended up on the pi.

I'd like to import them back into the Winbox, but they are not in the import/export list of either machine.

That said, is there a method to synch these exports between machines?

Russ

Now I am totally confused :confused:
Sorry Russ

OK, forget it. I just won't attempt to save anything from now on.

Russ

On second thought, I can export to clipboard, paste it into a text file, and save it that way. At least I'll have something.

If you used Export > Library They will be in the lib folder in your .node-red folder.

If you export to lib on the windows machine, the flow will be saved on the windows file system.

When you import from lib on the pi, it will look on it's own file system not the windows file system

There is no connection between the two unless you copy them over.

If you open the node-red editor for both the windows box and the pi in your windows browser, side by side,
you can simply export to tclipboard, change tab to the pi node-red editor, then import from clipboard. No files no fuss no muss.

1 Like

I have just tried it on Ubuntu and it goes to .node-red/lib/flows

Oops. Lets clear it up for anyone reading....

By default, the lib [folder] when running node-red on windows is c:\users\username\.node-red\lib where username is the user who fired up node-red

Steve,

I do not have any N-R files at that (Winbox) location, or any other location on my C:\ drive for that matter.

This may be the issue: I have N-R installed on my pi, which is located at my (very uncomfortable) office desk. I do NOT have N-R installed on my Winbox. I only access & edit the pi's N-R install from my Winbox browser - from my recliner in the living room. However, there are times when I use the pi's browser to edit because I need to physically see what the pi pins are doing on my breadboard. Occasionally I get a "merge" message because both browsers have made changes to the same install, but this hasn't been a problem. Later, I'll try an export from the pi's browser and make sure it saves to the pi folder.

I assumed exporting a node or flow would save to the pi folder (regardless of which machine's broswer is used) because the only install is on the pi, but things saved from the Winbox browser do not end up anywhere. No error messages either!

Russ

Where the browser is running is irrelevant. The files should be stored in ~/.node-red/lib/flows on the pi, unless your install on the pi is unusual.

N-R in the default location, where it was on the image-file initially installed on pi. There are two export files in the correct location, may have been exported from the pi browser weeks ago, don't remember. I do know that nothing exported from the Winbox makes it anywhere (that I can find). Can you recommend a file search tool for Raspbian? I don't know squat about linux...

Russ

Can you stop node-red and start it again in a terminal and post the resulting output here please. Copy/paste it and use the </> button at the top of the forum entry window when pasting it in. Check it shows the correct flows when you start it in the terminal to make sure it is running correctly.

Are you really just trying to duplicate your work on the win machine to the pi machine? If so, IMHO, I would use projects and github. This way you also have a backup up in the cloud and it is fairly easy to implement and use it. Nick just helped me do it. Here is a link to an article that he wrote describing the steps to set it up.

https://knolleary.net/node-red-workshop-photobooth/part4/one-more-thing.html

The OP does not have node-red running on the Windows machine, only on the pi.

That is confusing. From a curiosity standpoint, how is he saving flows on the winbox? Or copying them to the clipboard?

He/she isn't, he is using Export > Library but then can't find them on the Win box or the pi.

Granted it is confusing. I based my response on this part of one of his messages

"On second thought, I can export to clipboard, paste it into a text file, and save it that way. At least I'll have something."

No need to reply. He can use what I posted or just ignore it if it is not applicable.

So to be absolutely clear, you have just one node-RED server, which is running on a Pi.

If so, then again reading your first few posts, you are trying to export it's flows, and then import them again.

Can I ask, just so I understand your endgame, what is the purpose in importing the same flows to the same server that you've just exported them from?