# Flows do not survive a restart

**URL:** <https://discourse.nodered.org/t/flows-do-not-survive-a-restart/39731>\
**Category:** General\
**Created:** [25 January 2021 21:01 UTC](https://discourse.nodered.org/t/flows-do-not-survive-a-restart/39731 "2021-01-25T21:01:39Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Paka46](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/paka46/32/35913_2.png) [@Paka46](https://discourse.nodered.org/u/Paka46)\
**Post date:** [25 January 2021 21:01 UTC](https://discourse.nodered.org/t/flows-do-not-survive-a-restart/39731/1 "2021-01-25T21:01:39Z")

</div>

I am running Node-Red version 1.2.7 on Raspberry Pi. This was initially installed as version 1.1.3

The initial install and subsequent upgrade were done using the recommended script from:  
[https://nodered.org/docs/getting-started/raspberrypi](https://nodered.org/docs/getting-started/raspberrypi)

Node-Red is setup to run as a service.

The .node-red folder appears as:  
 ![Node-Red-1.2.7-03-BeforeRestart](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/c/3/c35e22b40c2e953451ffece0f1a65fbccd6cd5e7.jpeg)

The following commands are issued from the Terminal:

> > node-red-stop  
> > sudo reboot

After a the reboot, the .node-red folder appears as:  
 ![Node-Red-1.2.7-04-AfterRestart](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/5/9/59706856a9a2a7384668ad65f99d70fd9a1b53ca.jpeg)

New file items from version 1.2.7 of Node-Red are missing and the flow files are replace by much older files.

What is going on?

Where do the old files come from (i.e. where are they on the Pi)?

How do I stop this from happening (so that the system might survive a power failure) ?

Thanks.

---

<div class="post-metadata">

**Author:** ![Colin](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/colin/32/17040_2.png) [@Colin](https://discourse.nodered.org/u/Colin)\
**Post date:** [25 January 2021 21:19 UTC](https://discourse.nodered.org/t/flows-do-not-survive-a-restart/39731/2 "2021-01-25T21:19:50Z")

</div>

> [@Paka46](#):
>
> How do I stop this from happening

Throw the SD card away and use a new one. It is quite a common mode of failure of the cards that they appear to work fine except that the new data is not being saved in the flash storage.  
If it would save you a lot of time then it is probably ok to make an image copy of the old card onto the new one before you bin it. However it would be better to start from scratch and restore your flows file from your most recent backup onto the new card.

**[Edit]** Make sure you use a good quality branded SD card from a reputable source. Don't use cheap ones from ebay, it is a false economy.

---

<div class="post-metadata">

**Author:** ![Paka46](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/paka46/32/35913_2.png) [@Paka46](https://discourse.nodered.org/u/Paka46)\
**Post date:** [25 January 2021 21:32 UTC](https://discourse.nodered.org/t/flows-do-not-survive-a-restart/39731/3 "2021-01-25T21:32:40Z")

</div>

Thank you ... sounds like a plausible solution. I happen to be using a "SanDisk High Endurance" card but anything can fail.

---

<div class="post-metadata">

**Author:** ![Colin](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/colin/32/17040_2.png) [@Colin](https://discourse.nodered.org/u/Colin)\
**Post date:** [25 January 2021 21:35 UTC](https://discourse.nodered.org/t/flows-do-not-survive-a-restart/39731/4 "2021-01-25T21:35:19Z")

</div>

I have not been impressed with SanDisk, but stopped using them a few years ago so they may be ok now.

---

<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:** [26 March 2021 21:36 UTC](https://discourse.nodered.org/t/flows-do-not-survive-a-restart/39731/5 "2021-03-26T21:36:14Z")

</div>

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