# Launching node-red(error of infinite loop)

**URL:** <https://discourse.nodered.org/t/launching-node-red-error-of-infinite-loop/9548>\
**Category:** General\
**Created:** [28 March 2019 13:03 UTC](https://discourse.nodered.org/t/launching-node-red-error-of-infinite-loop/9548 "2019-03-28T13:03:40Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![hebergeweb](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/hebergeweb/32/6394_2.png) [@hebergeweb](https://discourse.nodered.org/u/hebergeweb)\
**Post date:** [28 March 2019 13:03 UTC](https://discourse.nodered.org/t/launching-node-red-error-of-infinite-loop/9548/1 "2019-03-28T13:03:41Z")

</div>

Hi,  
when I start node-red, I see this error:

 ![error](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/2X/3/3e4a8c105faa193cd1f4d061e0d36f16d3b1626e.png)

---

<div class="post-metadata">

**Author:** ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)\
**Post date:** [28 March 2019 13:26 UTC](https://discourse.nodered.org/t/launching-node-red-error-of-infinite-loop/9548/2 "2019-03-28T13:26:50Z")

</div>

I would guess that you have some code that has an infinite loop somewhere.

However, you need to share details about your environment (node.js, node-red,etc version numbers, OS, platform).

Also, sharing your flow might be helpful.

---

<div class="post-metadata">

**Author:** ![hebergeweb](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/hebergeweb/32/6394_2.png) [@hebergeweb](https://discourse.nodered.org/u/hebergeweb)\
**Post date:** [28 March 2019 13:33 UTC](https://discourse.nodered.org/t/launching-node-red-error-of-infinite-loop/9548/3 "2019-03-28T13:33:35Z")

</div>

yes i have an infinite loop somewhere, I know where is this error but how can I delete the node through cli or file ?

---

<div class="post-metadata">

**Author:** ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)\
**Post date:** [28 March 2019 13:42 UTC](https://discourse.nodered.org/t/launching-node-red-error-of-infinite-loop/9548/4 "2019-03-28T13:42:45Z")

</div>

Ah, sorry, of course.

If you are using the latest version of Node-RED, you should be able to restart it using the safe option so that the flows don't automatically start.

---

<div class="post-metadata">

**Author:** ![ukmoose](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/ukmoose/32/13_2.png) [@ukmoose](https://discourse.nodered.org/u/ukmoose)\
**Post date:** [28 March 2019 13:44 UTC](https://discourse.nodered.org/t/launching-node-red-error-of-infinite-loop/9548/5 "2019-03-28T13:44:05Z")

</div>

- Add `--safe` mode flag to allow starting without flows running. This can be used if a flow is causing Node-RED to crash - starting in safe mode will allow the editor to be used to modify the flow and then deploy the change to take it out of safe mode.

---

<div class="post-metadata">

**Author:** ![hebergeweb](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/hebergeweb/32/6394_2.png) [@hebergeweb](https://discourse.nodered.org/u/hebergeweb)\
**Post date:** [28 March 2019 13:49 UTC](https://discourse.nodered.org/t/launching-node-red-error-of-infinite-loop/9548/6 "2019-03-28T13:49:25Z")

</div>

I have version 0.19.6, where i put --safe mode

---

<div class="post-metadata">

**Author:** ![ukmoose](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/ukmoose/32/13_2.png) [@ukmoose](https://discourse.nodered.org/u/ukmoose)\
**Post date:** [28 March 2019 13:50 UTC](https://discourse.nodered.org/t/launching-node-red-error-of-infinite-loop/9548/7 "2019-03-28T13:50:16Z")

</div>

Unfortunately it only came in v0.20

---

<div class="post-metadata">

**Author:** ![knolleary](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/knolleary/32/3_2.png) [@knolleary](https://discourse.nodered.org/u/knolleary)\
**Post date:** [28 March 2019 14:10 UTC](https://discourse.nodered.org/t/launching-node-red-error-of-infinite-loop/9548/8 "2019-03-28T14:10:46Z")

</div>

> [@hebergeweb](#):
>
> I have version 0.19.6, where i put --safe mode

As @ukmoose says, that option was only added in 0.20.

You can either hand-edit your flow file, identify the offending node and delete it, or move the flow file to a new location so Node-RED starts with a blank set of flows. You can then import your old flows bit by bit.

If you aren't sure where your flow file is, Node-RED logs the full path to the file its using when it starts up.

---

<div class="post-metadata">

**Author:** ![hebergeweb](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/hebergeweb/32/6394_2.png) [@hebergeweb](https://discourse.nodered.org/u/hebergeweb)\
**Post date:** [28 March 2019 14:28 UTC](https://discourse.nodered.org/t/launching-node-red-error-of-infinite-loop/9548/9 "2019-03-28T14:28:00Z")

</div>

thank you, it works now when i upgrade NR to v0.20 and use the safe mode
