# Stuck in deploy

**URL:** <https://discourse.nodered.org/t/stuck-in-deploy/20969>\
**Category:** General\
**Created:** [28 January 2020 20:14 UTC](https://discourse.nodered.org/t/stuck-in-deploy/20969 "2020-01-28T20:14:48Z")\
**Posts on this page:** 19\
**Page:** 1

<div class="post-metadata">

**Author:** ![theSushi](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/thesushi/32/47459_2.png) [@theSushi](https://discourse.nodered.org/u/theSushi)\
**Post date:** [28 January 2020 20:14 UTC](https://discourse.nodered.org/t/stuck-in-deploy/20969/1 "2020-01-28T20:14:48Z")

</div>

hi guys i have problem i do deploy and now i cant connect to my node red... what i need to do i know what i am last do if is posible open i can easy remove thise node. ty and sorry for my eng

edit: now i am looking on google find node-red --safe function but when i run this i can see dasboard but ther is no my flow all is empty

---

<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:** [28 January 2020 21:02 UTC](https://discourse.nodered.org/t/stuck-in-deploy/20969/2 "2020-01-28T21:02:38Z")

</div>

Show us what you see in the terminal window when you run with --safe

---

<div class="post-metadata">

**Author:** ![theSushi](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/thesushi/32/47459_2.png) [@theSushi](https://discourse.nodered.org/u/theSushi)\
**Post date:** [28 January 2020 21:06 UTC](https://discourse.nodered.org/t/stuck-in-deploy/20969/3 "2020-01-28T21:06:59Z")

</div>

![15802455901237322764653132849146](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/2/9/29962178f816434a6a16c9b5b0a2b529da121907.jpeg)

this flow run my terrari control temperature humiditi heating foging and now dont work my lihard is not happy and i am mad bc i am make this 😥

---

<div class="post-metadata">

**Author:** ![Paul-Reed](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/paul-reed/32/66906_2.png) [@Paul-Reed](https://discourse.nodered.org/u/Paul-Reed)\
**Post date:** [28 January 2020 21:25 UTC](https://discourse.nodered.org/t/stuck-in-deploy/20969/4 "2020-01-28T21:25:16Z")

</div>

Why are you running it as root (sudo) & how did you install node-RED? It appears that you didn't use the [installation script](https://nodered.org/docs/getting-started/raspberrypi).

---

<div class="post-metadata">

**Author:** ![theSushi](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/thesushi/32/47459_2.png) [@theSushi](https://discourse.nodered.org/u/theSushi)\
**Post date:** [28 January 2020 21:28 UTC](https://discourse.nodered.org/t/stuck-in-deploy/20969/5 "2020-01-28T21:28:51Z")

</div>

i think i need with sudo run... idc how i am install node red. i install them before 1year

---

<div class="post-metadata">

**Author:** ![theSushi](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/thesushi/32/47459_2.png) [@theSushi](https://discourse.nodered.org/u/theSushi)\
**Post date:** [28 January 2020 21:35 UTC](https://discourse.nodered.org/t/stuck-in-deploy/20969/6 "2020-01-28T21:35:53Z")

</div>

![15802472659932715301567938230670](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/0/e/0edce969f478ad9964c48824ee4deb8739d36da8.jpeg) ok now i am run without sudo

edit: but now i cant open NR in browser

---

<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:** [28 January 2020 21:54 UTC](https://discourse.nodered.org/t/stuck-in-deploy/20969/7 "2020-01-28T21:54:42Z")

</div>

I am not sure that the --safe option was present in node-red 0.18.7. It certainly does not seem to have started in safe mode.  
In your situation I would probably upgrade using the pi install/upgrade script. Paul posted a link to that earlier.

---

<div class="post-metadata">

**Author:** ![theSushi](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/thesushi/32/47459_2.png) [@theSushi](https://discourse.nodered.org/u/theSushi)\
**Post date:** [28 January 2020 22:22 UTC](https://discourse.nodered.org/t/stuck-in-deploy/20969/8 "2020-01-28T22:22:58Z")

</div>

ty soo much i install script and run --safe and change this problematic function. i post photo of function.  
i try make function which will light my heater! depending on the time of day eg at night (20h-7h) to keep my temperature no higher than 20 C and per day (7h-20h) no more than 27 C  
and try with if else but my problem is if I put 28 C when it drops to 27.9 the heater starts for 2 seconds and turns off. i would make it oscillate 2 C

[f nodered|690x388](https://discourse.nodered.org/uploads/short-url/nYBOOJh9W2iSJd7RBbZadbCXjdY.png)

thank you all for helping me solve my first problem

---

<div class="post-metadata">

**Author:** ![Paul-Reed](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/paul-reed/32/66906_2.png) [@Paul-Reed](https://discourse.nodered.org/u/Paul-Reed)\
**Post date:** [28 January 2020 22:36 UTC](https://discourse.nodered.org/t/stuck-in-deploy/20969/9 "2020-01-28T22:36:15Z")

</div>

The second problem should be easy to solve.  
But instead of a screenshot, please post your function node code as text, so we can edit it.

---

<div class="post-metadata">

**Author:** ![theSushi](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/thesushi/32/47459_2.png) [@theSushi](https://discourse.nodered.org/u/theSushi)\
**Post date:** [28 January 2020 22:46 UTC](https://discourse.nodered.org/t/stuck-in-deploy/20969/10 "2020-01-28T22:46:44Z")

</div>

[{"id":"d44e2a26.880158","type":"function","z":"d8e8a97b.a83608","name":"control temperature","func":"//if (msg.payload \< 26) {\n// msg.payload=0;\n//} else if (msg.payload \< 28) {\n// msg.payload = "do nothing";\n//} else {\n//msg.payload=1;\n//}\n//return msg;","outputs":1,"noerr":0,"x":790,"y":1260,"wires":[["daf3059c.139e88","c608f6b.70ee208"]]}]

this is function node

---

<div class="post-metadata">

**Author:** ![Paul-Reed](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/paul-reed/32/66906_2.png) [@Paul-Reed](https://discourse.nodered.org/u/Paul-Reed)\
**Post date:** [28 January 2020 22:52 UTC](https://discourse.nodered.org/t/stuck-in-deploy/20969/11 "2020-01-28T22:52:42Z")

</div>

> [@Paul-Reed](#):
>
> But instead of a screenshot, please post your function node code as text, so we can edit it.

Not the whole flow!! just the function node code.

In any event, you need to introduce hysteresis to prevent that from happening, take a look at [node-red-contrib-ramp-thermostat](https://flows.nodered.org/node/node-red-contrib-ramp-thermostat) which can manage that for you.  
It's a better solution than using a function node.

---

<div class="post-metadata">

**Author:** ![theSushi](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/thesushi/32/47459_2.png) [@theSushi](https://discourse.nodered.org/u/theSushi)\
**Post date:** [28 January 2020 23:03 UTC](https://discourse.nodered.org/t/stuck-in-deploy/20969/12 "2020-01-28T23:03:10Z")

</div>

ok man i will see thise ramp thermostat

---

<div class="post-metadata">

**Author:** ![theSushi](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/thesushi/32/47459_2.png) [@theSushi](https://discourse.nodered.org/u/theSushi)\
**Post date:** [29 January 2020 05:16 UTC](https://discourse.nodered.org/t/stuck-in-deploy/20969/13 "2020-01-29T05:16:51Z")

</div>

i try make with ramp thermostat but probubli dont read my input and i doont have output

[{"id":"77c1a06.0ec066","type":"ramp-thermostat","z":"d8e8a97b.a83608","name":"","profile":"6ec0545d.80524c","hysteresisplus":"1","hysteresisminus":"1","x":780,"y":1220,"wires":[["c608f6b.70ee208","daf3059c.139e88"],["8346b25e.f1215"],["352f2789.4a51c8"]],"inputLabels":["msg.payload"]},{"id":"6ec0545d.80524c","type":"profile","z":"d8e8a97b.a83608","d":true,"name":"controll temperature","time1":"00:00","temp1":"20","time2":"04:00","temp2":"21","time3":"07:00","temp3":"21","time4":"10:00","temp4":"23","time5":"12:00","temp5":"25","time6":"15:00","temp6":"27","time7":"18:00","temp7":"25","time8":"20:00","temp8":"23","time9":"22:00","temp9":"21","time10":"23:59","temp10":"20"}]

---

<div class="post-metadata">

**Author:** ![Paul-Reed](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/paul-reed/32/66906_2.png) [@Paul-Reed](https://discourse.nodered.org/u/Paul-Reed)\
**Post date:** [29 January 2020 09:33 UTC](https://discourse.nodered.org/t/stuck-in-deploy/20969/14 "2020-01-29T09:33:22Z")

</div>

Probably because the node was set as disabled.

Your hysteresis is also maybe a little high, try 0.5 + & 0.5 - which will give you a range of 1 degree.  
Also remember that when the time is between 2 time points, the corresponding temperature setting will also be between the two temperature points...

For example, with a config of;

| Time | Temp |
| --- | --- |
| 14:00 | 20 |
| 16:00 | 22 |

At 14:00, the target temp is 20 deg  
At 15:00, the target temp is 21 deg (and not 20 deg!!)  
At 16:00, the target temp is 22 deg

To try and understand how the node hysteresis works, try this simple example, and experiment injecting the different values. Start injecting the lowest temp, and continue increasing it to the maximum, then do the opposite and gradually lower the temp back down.

```auto
[{"id":"8828403c.b6bc9","type":"inject","z":"b3b413d1.05b1b","name":"","topic":"","payload":"19.4","payloadType":"num","repeat":"","crontab":"","once":false,"onceDelay":0.1,"x":380,"y":130,"wires":[["7a3e2d05.2d0804"]]},{"id":"94b00f42.c9b99","type":"debug","z":"b3b413d1.05b1b","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","x":735,"y":185,"wires":[]},{"id":"3e47ae98.32f842","type":"inject","z":"b3b413d1.05b1b","name":"","topic":"","payload":"19.8","payloadType":"num","repeat":"","crontab":"","once":false,"onceDelay":0.1,"x":385,"y":165,"wires":[["7a3e2d05.2d0804"]]},{"id":"b8d36f20.76c1f","type":"inject","z":"b3b413d1.05b1b","name":"","topic":"","payload":"20.4","payloadType":"num","repeat":"","crontab":"","once":false,"onceDelay":0.1,"x":380,"y":200,"wires":[["7a3e2d05.2d0804"]]},{"id":"7a3e2d05.2d0804","type":"ramp-thermostat","z":"b3b413d1.05b1b","name":"","profile":"aca00e2.03051f","hysteresisplus":"0.5","hysteresisminus":"0.5","x":540,"y":180,"wires":[["94b00f42.c9b99"],[],[]]},{"id":"78af87ad.d49fa8","type":"inject","z":"b3b413d1.05b1b","name":"","topic":"","payload":"20.6","payloadType":"num","repeat":"","crontab":"","once":false,"onceDelay":0.1,"x":380,"y":235,"wires":[["7a3e2d05.2d0804"]]},{"id":"aca00e2.03051f","type":"profile","z":"","name":"Control temp","time1":"00:00","temp1":"20","time2":"23:59","temp2":"20","time3":"","temp3":"","time4":"","temp4":"","time5":"","temp5":"","time6":"","temp6":"","time7":"","temp7":"","time8":"","temp8":"","time9":"","temp9":"","time10":"","temp10":""}]

```

---

<div class="post-metadata">

**Author:** ![theSushi](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/thesushi/32/47459_2.png) [@theSushi](https://discourse.nodered.org/u/theSushi)\
**Post date:** [29 January 2020 16:17 UTC](https://discourse.nodered.org/t/stuck-in-deploy/20969/15 "2020-01-29T16:17:01Z")

</div>

i rhink i have problem bc i read from mqtt temp

```auto
[{"id":"53fe1dfa.050d84","type":"mqtt in","z":"d8e8a97b.a83608","name":"/espDHT11terari/DHT11/Temp","topic":"/espDHT11terari/DHT11/Temp","qos":"2","broker":"19efa301.6c402d","x":480,"y":1280,"wires":[["a4e1b4cf.38fcd8","da0c378c.df0d68","4910fc94.8b85d4","77c1a06.0ec066","e284c32d.7fa8f"]]},{"id":"77c1a06.0ec066","type":"ramp-thermostat","z":"d8e8a97b.a83608","name":"","profile":"6ec0545d.80524c","hysteresisplus":"0.5","hysteresisminus":"0.5","x":840,"y":1220,"wires":[["daf3059c.139e88"],["8346b25e.f1215"],["352f2789.4a51c8"]]},{"id":"19efa301.6c402d","type":"mqtt-broker","z":"","name":"","broker":"192.168.178.35","port":"1883","tls":"","clientid":"","usetls":false,"compatmode":true,"keepalive":"15","cleansession":true,"birthTopic":"","birthQos":"0","birthPayload":"","closeTopic":"","closeQos":"0","closePayload":"","willTopic":"","willQos":"0","willPayload":""},{"id":"6ec0545d.80524c","type":"profile","z":"","name":"controll temperature","time1":"00:00","temp1":"20","time2":"04:00","temp2":"21","time3":"07:00","temp3":"21","time4":"10:00","temp4":"23","time5":"12:00","temp5":"25","time6":"15:00","temp6":"27","time7":"18:00","temp7":"25","time8":"20:00","temp8":"23","time9":"22:00","temp9":"21","time10":"23:59","temp10":"20"}]

```

---

<div class="post-metadata">

**Author:** ![Paul-Reed](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/paul-reed/32/66906_2.png) [@Paul-Reed](https://discourse.nodered.org/u/Paul-Reed)\
**Post date:** [29 January 2020 19:18 UTC](https://discourse.nodered.org/t/stuck-in-deploy/20969/16 "2020-01-29T19:18:53Z")

</div>

What exactly is the problem?  
If it's a different problem, then it needs to be a new forum thread. This thread is about 'Stuck in deploy'.

---

<div class="post-metadata">

**Author:** ![theSushi](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/thesushi/32/47459_2.png) [@theSushi](https://discourse.nodered.org/u/theSushi)\
**Post date:** [29 January 2020 20:18 UTC](https://discourse.nodered.org/t/stuck-in-deploy/20969/17 "2020-01-29T20:18:20Z")

</div>

ofc this is other problem i know what i need to do but idc how i have comunication with mtqq and then ramp-thermostat dont recognizez payload idc how to change mtqq to payload

---

<div class="post-metadata">

**Author:** ![Paul-Reed](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/paul-reed/32/66906_2.png) [@Paul-Reed](https://discourse.nodered.org/u/Paul-Reed)\
**Post date:** [29 January 2020 20:25 UTC](https://discourse.nodered.org/t/stuck-in-deploy/20969/18 "2020-01-29T20:25:15Z")

</div>

> [@theSushi](#):
>
> mtqq and then ramp-thermostat dont recognizez payload

Then start a new forum thread with that problem, and I'm sure you will get help.  
You need to post in that thread what you are feeding into the ramp-thermostat (attach a debug node and copy the message).

---

<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:** [12 February 2020 20:30 UTC](https://discourse.nodered.org/t/stuck-in-deploy/20969/19 "2020-02-12T20:30:24Z")

</div>

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