title
Best-practices & guides for Node-RED

How to Recover Accidentally Deleted or Changed Node-RED Flows

In this tutorial, you will learn how to recover accidentally deleted or changed Node-RED flows. Losing a flow can be frustrating, but there are steps you can take to recover the old backup. This guide will provide you with the steps you need to follow to restore the backup and recover the lost flow.

How to Recover Accidentally Deleted or Changed Node-RED Flows

Node-RED is an open-source flow-based programming tool that provides an easy-to-use graphical interface for developing applications. Sometimes, you may accidentally delete or change a Node-RED flow, which can be frustrating. In this guide, we will provide step-by-step instructions on how to recover accidentally deleted or changed Node-RED flows.

Instructions

  1. Stop immediately doing anything in Node-RED.
  2. Open UMHLens / OpenLens and navigate to the Node-RED pod.
  3. Open the shell of that pod
  4. Enter the following command in the console to restore the backup:
    cp /data/.flows.json.backup /data/flows.json

    This will restore the old backup and recover the lost flow.
  5. Close the console.

Stay up-to-date

Subscribe to the UMH Learning Hub Newsletter to receive the latest updates and gain early access to our blog posts.

Subscribe