# Node-RED Flows Disappearing

**URL:** <https://discourse.nodered.org/t/node-red-flows-disappearing/34919>\
**Category:** General\
**Created:** [27 October 2020 23:09 UTC](https://discourse.nodered.org/t/node-red-flows-disappearing/34919 "2020-10-27T23:09:37Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![liiontamer](https://avatars.discourse-cdn.com/v4/letter/l/9fc29f/32.png) [@liiontamer](https://discourse.nodered.org/u/liiontamer)\
**Post date:** [27 October 2020 23:09 UTC](https://discourse.nodered.org/t/node-red-flows-disappearing/34919/1 "2020-10-27T23:09:37Z")

</div>

Hi,

Having an issue with my flows disappearing on startup - it's happened about 3 times over the last 2 months.

My Node-RED instance runs on my laptop and I only switch on the instance when I need to do some work on it.

I don't make any changes to the file system on the laptop and access the instance via localhost:1880 each time.

Any help would be much appreciated.

Node-RED startup log below however, it's working fine at the moment;

```auto
Welcome to Node-RED

===================

27 Oct 18:02:33 - [info] Node-RED version: v1.1.3

27 Oct 18:02:33 - [info] Node.js version: v12.18.4

27 Oct 18:02:33 - [info] Darwin 19.6.0 x64 LE

27 Oct 18:02:33 - [info] Loading palette nodes

27 Oct 18:02:35 - [info] +-----------------------------------------------------

27 Oct 18:02:35 - [info] | uibuilder initialised:

27 Oct 18:02:35 - [info] | root folder: /Users/user/.node-red/uibuilder

27 Oct 18:02:35 - [info] | version . .: 2.0.8

27 Oct 18:02:35 - [info] | packages . : vue,bootstrap,bootstrap-vue,jquery,socket.io

27 Oct 18:02:35 - [info] +-----------------------------------------------------

27 Oct 18:02:35 - [info] Dashboard version 2.23.3 started at /ui

27 Oct 18:02:35 - [info] Settings file : /Users/user/.node-red/settings.js

27 Oct 18:02:35 - [info] Context store : 'default' [module=memory]

27 Oct 18:02:35 - [info] User directory : /Users/user/.node-red

27 Oct 18:02:35 - [warn] Projects disabled : editorTheme.projects.enabled=false

27 Oct 18:02:35 - [info] Flows file : /Users/user/.node-red/flows_MacBook-Pro.lan1.json

27 Oct 18:02:35 - [info] Server now running at http://127.0.0.1:1880/

27 Oct 18:02:35 - [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.

---------------------------------------------------------------------

27 Oct 18:02:35 - [info] Starting flows

27 Oct 18:02:35 - [error] [enocean in:6715590c.265248] TypeError: Cannot read property 'username' of undefined

27 Oct 18:02:35 - [error] [openweathermap:6f27bc67.142a44] No API key set

27 Oct 18:02:35 - [error] [openweathermap:1a12d312.6e23cd] No API key set

27 Oct 18:02:35 - [error] [openweathermap:469e4dc3.3cc9a4] No API key set

27 Oct 18:02:35 - [error] [enocean in:8788cbc3.4265f8] TypeError: Cannot read property 'username' of undefined

27 Oct 18:02:35 - [error] [openweathermap:8d25e229.8a6ed] No API key set

27 Oct 18:02:35 - [info] Started flows

(node:12729) Warning: Setting the NODE_TLS_REJECT_UNAUTHORIZED environment variable to '0' makes TLS connections and HTTPS requests insecure by disabling certificate verification.

27 Oct 18:02:36 - [error] [file in:EcobeeTokens] Error: ENOENT: no such file or directory, open '/home/pi/data/ecobee_token/test.log'

27 Oct 18:02:36 - [error] [function:Define Access and Refresh Tokens] TypeError: Cannot read property 'refresh_token' of undefined

27 Oct 18:02:41 - [error] [function:Display temperature] TypeError: Cannot read property 'length' of undefined

```

---

<div class="post-metadata">

**Author:** ![dceejay](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dceejay/32/38_2.png) [@dceejay](https://discourse.nodered.org/u/dceejay)\
**Post date:** [27 October 2020 23:15 UTC](https://discourse.nodered.org/t/node-red-flows-disappearing/34919/2 "2020-10-27T23:15:39Z")

</div>

Hi yes as Nick suggested over there - [🎉 Node-RED 1.2.2 released](https://discourse.nodered.org/t/node-red-1-2-2-released/34528/32) the most likely cause is dhcp on your network giving you a different hostname for your laptop - in the log above - `MacBook-Pro.lan1` - If you look in your ~/.node-red directory you will probably find several different flows\_ files that are the missing ones... you can edit your settings.js file to set the flow file to a fixed name and it won't move again.

---

<div class="post-metadata">

**Author:** ![ristomatti](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/ristomatti/32/5857_2.png) [@ristomatti](https://discourse.nodered.org/u/ristomatti)\
**Post date:** [28 October 2020 07:18 UTC](https://discourse.nodered.org/t/node-red-flows-disappearing/34919/3 "2020-10-28T07:18:54Z")

</div>

To complement Dave's comment above, the `~/.node-red` dir on your Windows system is `/Users/user/.node-red`. Linux/OS X typically alias `~` as the user's home dir. I'm not aware of Windows having that(?).

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)\
**Post date:** [27 December 2020 07:19 UTC](https://discourse.nodered.org/t/node-red-flows-disappearing/34919/4 "2020-12-27T07:19:03Z")

</div>

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