# Connection Lost (Node-RED Snap)

**URL:** https://discourse.nodered.org/t/connection-lost-node-red-snap/1683
**Category:** Dashboard
**Created:** [19 July 2018 07:46 UTC](https://discourse.nodered.org/t/connection-lost-node-red-snap/1683 "2018-07-19T07:46:00Z")
**Posts on this page:** 19
**Page:** 1

<div class="post-metadata">

### Author: ![JoseGodinho](https://avatars.discourse-cdn.com/v4/letter/j/f4b2a3/32.png) [@JoseGodinho](https://discourse.nodered.org/u/JoseGodinho)
#### Post date: [19 July 2018 07:46 UTC](https://discourse.nodered.org/t/connection-lost-node-red-snap/1683/1 "2018-07-19T07:46:00Z")

</div>

Hello All

I don´t know if its coincidence or not, but after the dashboard node upgrade,every time i try to enter the dashboard i have the message " Connection Lost " in a recurrent way every second or so. Albeit the node red editor is still working as normal.

Looking forward to have any support.

Thank you

---

<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: [19 July 2018 08:29 UTC](https://discourse.nodered.org/t/connection-lost-node-red-snap/1683/2 "2018-07-19T08:29:11Z")

</div>

you may need to flush the browser cache. cmd/ctrl shift reload a couple of times shuold do it - but otherwise (on chrome) - go to chrome://appcache-internals/ and manually delete the node-red manifest.

---

<div class="post-metadata">

### Author: ![JoseGodinho](https://avatars.discourse-cdn.com/v4/letter/j/f4b2a3/32.png) [@JoseGodinho](https://discourse.nodered.org/u/JoseGodinho)
#### Post date: [19 July 2018 10:13 UTC](https://discourse.nodered.org/t/connection-lost-node-red-snap/1683/3 "2018-07-19T10:13:52Z")

</div>

Thank You dceejay,

solved in chrome but still the same issues in iPhone safari, any suggestions?

---

<div class="post-metadata">

### Author: ![JoseGodinho](https://avatars.discourse-cdn.com/v4/letter/j/f4b2a3/32.png) [@JoseGodinho](https://discourse.nodered.org/u/JoseGodinho)
#### Post date: [19 July 2018 10:24 UTC](https://discourse.nodered.org/t/connection-lost-node-red-snap/1683/4 "2018-07-19T10:24:19Z")

</div>

dceejay.. cleand the cache from all the browser and its ok

Thank You once again for you prompt and effective support

---

<div class="post-metadata">

### Author: ![ceejm1](https://avatars.discourse-cdn.com/v4/letter/c/53a042/32.png) [@ceejm1](https://discourse.nodered.org/u/ceejm1)
#### Post date: [3 December 2018 14:42 UTC](https://discourse.nodered.org/t/connection-lost-node-red-snap/1683/5 "2018-12-03T14:42:44Z")

</div>

Hello, I am seeing this on multiple browsers. I've tried flushing caches and visiting from browsers that have never seen the dashboard before but no change.

Dashboard version 2.11.0 running on ubuntu 18.04 LTS installed with snap

Any thoughts greatly appreciated.

James

---

<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: [3 December 2018 17:16 UTC](https://discourse.nodered.org/t/connection-lost-node-red-snap/1683/6 "2018-12-03T17:16:32Z")

</div>

Do you mean you are seeing connection lost appearing every few seconds? If so what do you see in the node red log

---

<div class="post-metadata">

### Author: ![ceejm1](https://avatars.discourse-cdn.com/v4/letter/c/53a042/32.png) [@ceejm1](https://discourse.nodered.org/u/ceejm1)
#### Post date: [4 December 2018 21:01 UTC](https://discourse.nodered.org/t/connection-lost-node-red-snap/1683/7 "2018-12-04T21:01:23Z")

</div>

Thanks Colin. Where would I find the node red log bearing in mind i've installed with snap.

Thanks  
James

---

<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: [4 December 2018 21:16 UTC](https://discourse.nodered.org/t/connection-lost-node-red-snap/1683/8 "2018-12-04T21:16:56Z")

</div>

You can see the log with

```
journalctl -f -u snap.node-red*
```

---

<div class="post-metadata">

### Author: ![ceejm1](https://avatars.discourse-cdn.com/v4/letter/c/53a042/32.png) [@ceejm1](https://discourse.nodered.org/u/ceejm1)
#### Post date: [4 December 2018 21:20 UTC](https://discourse.nodered.org/t/connection-lost-node-red-snap/1683/9 "2018-12-04T21:20:04Z")

</div>

Great. Thanks. I'm back at the machine in the morning so will check and report back.

James

---

<div class="post-metadata">

### Author: ![ceejm1](https://avatars.discourse-cdn.com/v4/letter/c/53a042/32.png) [@ceejm1](https://discourse.nodered.org/u/ceejm1)
#### Post date: [5 December 2018 10:49 UTC](https://discourse.nodered.org/t/connection-lost-node-red-snap/1683/10 "2018-12-05T10:49:46Z")

</div>

Dec 05 10:47:21 DC-4 node-red.node-red[16882]: 5 Dec 10:47:21 - [info] Node-RED version: v0.19.5  
Dec 05 10:47:21 DC-4 node-red.node-red[16882]: 5 Dec 10:47:21 - [info] Node.js version: v8.12.0  
Dec 05 10:47:21 DC-4 node-red.node-red[16882]: 5 Dec 10:47:21 - [info] Linux 4.15.0-39-generic x64 LE  
Dec 05 10:47:21 DC-4 node-red.node-red[16882]: 5 Dec 10:47:21 - [info] Loading palette nodes  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: 5 Dec 10:47:22 - [warn] rpi-gpio : Raspberry Pi specific node set inactive  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: 5 Dec 10:47:22 - [warn] rpi-gpio : Cannot find Pi RPi.GPIO python library  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: 5 Dec 10:47:22 - [info] Dashboard version 2.11.0 started at /ui  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: 5 Dec 10:47:22 - [info] Settings file : /root/snap/node-red/155/settings.js  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: 5 Dec 10:47:22 - [info] Context store : 'default' [module=memory]  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: 5 Dec 10:47:22 - [info] User directory : /root/snap/node-red/155  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: 5 Dec 10:47:22 - [warn] Projects disabled : editorTheme.projects.enabled=false  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: 5 Dec 10:47:22 - [info] Flows file : /root/snap/node-red/155/flows.json  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: 5 Dec 10:47:22 - [info] Server now running at [http://127.0.0.1:1880/](http://127.0.0.1:1880/)  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: 5 Dec 10:47:22 - [warn]  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: ---------------------------------------------------------------------  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: Your flow credentials file is encrypted using a system-generated key.  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: If the system-generated key is lost for any reason, your credentials  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: file will not be recoverable, you will have to delete it and re-enter  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: your credentials.  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: You should set your own key using the 'credentialSecret' option in  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: your settings file. Node-RED will then re-encrypt your credentials  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: file using your chosen key the next time you deploy a change.  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: ---------------------------------------------------------------------  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: 5 Dec 10:47:22 - [info] Starting flows  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: 5 Dec 10:47:22 - [info] [tcp out:ECU1] connecting to 192.168.8.101:3002  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: 5 Dec 10:47:22 - [info] [tcp out:ECU2] connecting to 192.168.8.102:3002  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: 5 Dec 10:47:22 - [info] Started flows  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: 5 Dec 10:47:22 - [info] [udp in:9dd3fbdd.7b138] udp listener at 0.0.0.0:7001  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: 5 Dec 10:47:22 - [info] [udp in:be82488e.ce8f5] udp listener at 0.0.0.0:7002  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: 5 Dec 10:47:22 - [info] [udp in:8c5fba52.9deb5] udp listener at 0.0.0.0:7003  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: 5 Dec 10:47:22 - [info] [udp in:8dfdf65e.75546] udp listener at 0.0.0.0:7004  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: 5 Dec 10:47:22 - [info] [udp in:65c646b4.1db2a8] udp listener at 0.0.0.0:7005  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: 5 Dec 10:47:22 - [info] [udp in:e1fa436e.a23338] udp listener at 0.0.0.0:7006  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: 5 Dec 10:47:22 - [info] [udp in:fa277899.242038] udp listener at 0.0.0.0:7007  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: 5 Dec 10:47:22 - [info] [udp in:7721a82d.d9cae8] udp listener at 0.0.0.0:7008  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: 5 Dec 10:47:22 - [info] [udp in:eac5113b.41868] udp listener at 0.0.0.0:7009  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: 5 Dec 10:47:22 - [info] [udp in:27dcfbaf.8c282c] udp listener at 0.0.0.0:7010  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: 5 Dec 10:47:22 - [info] [udp in:9ae3dd36.4ec3e8] udp listener at 0.0.0.0:7011  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: 5 Dec 10:47:22 - [info] [udp in:ec34e2a3.e80fd] udp listener at 0.0.0.0:7012  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: 5 Dec 10:47:22 - [info] [udp in:ac0a242f.bf1ca] udp listener at 0.0.0.0:7013  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: 5 Dec 10:47:22 - [info] [udp in:7732ed0c.6a09ac] udp listener at 0.0.0.0:7014  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: 5 Dec 10:47:22 - [info] [udp in:9eeef4d3.b924b] udp listener at 0.0.0.0:7015  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: 5 Dec 10:47:22 - [info] [udp in:5c40d986.5d148] udp listener at 0.0.0.0:7016  
Dec 05 10:47:22 DC-4 node-red.node-red[16882]: 5 Dec 10:47:22 - [info] [tcp out:ECU1] connected to 192.168.8.101:3002  
Dec 05 10:47:23 DC-4 node-red.node-red[16882]: 5 Dec 10:47:23 - [red] Uncaught Exception:  
Dec 05 10:47:23 DC-4 node-red.node-red[16882]: 5 Dec 10:47:23 - Error: spawn EACCES  
Dec 05 10:47:23 DC-4 node-red.node-red[16882]: at ChildProcess.spawn (internal/child\_process.js:313:11)  
Dec 05 10:47:23 DC-4 node-red.node-red[16882]: at exports.spawn (child\_process.js:503:9)  
Dec 05 10:47:23 DC-4 node-red.node-red[16882]: at Timeout.\_onTimeout (/snap/node-red/155/lib/node\_modules/node-red-node-ping/88-ping.js:15:62)  
Dec 05 10:47:23 DC-4 node-red.node-red[16882]: at ontimeout (timers.js:498:11)  
Dec 05 10:47:23 DC-4 node-red.node-red[16882]: at tryOnTimeout (timers.js:323:5)  
Dec 05 10:47:23 DC-4 node-red.node-red[16882]: at Timer.listOnTimeout (timers.js:290:5)  
Dec 05 10:47:23 DC-4 systemd[1]: snap.node-red.node-red.service: Main process exited, code=exited, status=1/FAILURE  
Dec 05 10:47:23 DC-4 systemd[1]: snap.node-red.node-red.service: Failed with result 'exit-code'.  
Dec 05 10:47:23 DC-4 systemd[1]: snap.node-red.node-red.service: Service hold-off time over, scheduling restart.  
Dec 05 10:47:23 DC-4 systemd[1]: snap.node-red.node-red.service: Scheduled restart job, restart counter is at 61284.  
Dec 05 10:47:23 DC-4 systemd[1]: Stopped Service for snap application node-red.node-red.  
Dec 05 10:47:23 DC-4 systemd[1]: Started Service for snap application node-red.node-red.

Does this shed any light on it?

Thanks  
James

---

<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: [5 December 2018 11:00 UTC](https://discourse.nodered.org/t/connection-lost-node-red-snap/1683/11 "2018-12-05T11:00:48Z")

</div>

Yes... for some reason the ping command does not have access and is failing... Remove it from your flow - for now.  
(Will need to fix that node to catch that error better - so thanks)

"Dec 05 10:47:23 DC-4 node-red.node-red[16882]: at Timeout.\_onTimeout (/snap/node-red/155/lib/node\_modules/node-red-node-ping/88-ping.js:15:62)"

---

<div class="post-metadata">

### Author: ![ceejm1](https://avatars.discourse-cdn.com/v4/letter/c/53a042/32.png) [@ceejm1](https://discourse.nodered.org/u/ceejm1)
#### Post date: [5 December 2018 11:07 UTC](https://discourse.nodered.org/t/connection-lost-node-red-snap/1683/12 "2018-12-05T11:07:19Z")

</div>

Thanks. Will try that.

When you say it doesn't have access, do you mean it can't resolve a ping to its target? The ping is fairly integral to this flow that monitors the status of various devices on the network.

FYI, the flow is copied directly from an installation on an RPi that runs without issue.

Thanks  
James

---

<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: [5 December 2018 11:18 UTC](https://discourse.nodered.org/t/connection-lost-node-red-snap/1683/13 "2018-12-05T11:18:08Z")

</div>

Running things in a snap means they are restricted in what they can do... (the whole point of snaps is to try to make these containers more secure) - so it needs to be investigated as to which bit of what is blocking the access...

The error is just a generic Error: spawn EACCES

It may be the fact that the ping node is trying to spawn an external ping command (which snap blocks) - most likely... or it may be that the snap blocks network icmp access - less likely - or something else... so yes needs investigation.

---

<div class="post-metadata">

### Author: ![ceejm1](https://avatars.discourse-cdn.com/v4/letter/c/53a042/32.png) [@ceejm1](https://discourse.nodered.org/u/ceejm1)
#### Post date: [5 December 2018 11:22 UTC](https://discourse.nodered.org/t/connection-lost-node-red-snap/1683/14 "2018-12-05T11:22:59Z")

</div>

OK. Thanks. I'm new to Ubuntu/Snap. Would i be better uninstalling from snap and reinstalling directly?

James

---

<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: [5 December 2018 11:30 UTC](https://discourse.nodered.org/t/connection-lost-node-red-snap/1683/15 "2018-12-05T11:30:34Z")

</div>

you could try `snap install node-red --classic` (after uninstalling first). This (should) install it un-contained and allow this to work... but... That's sort of not the point... but hey...

Failing that then yes you will need to do a "normal" install - for Ubuntu the Pi install script should work fine as they are both Debian based.

---

<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: [5 December 2018 13:51 UTC](https://discourse.nodered.org/t/connection-lost-node-red-snap/1683/16 "2018-12-05T13:51:42Z")

</div>

New version of ping node published so at least the new one catches the error and hopefully won't die... - it still won't actually run ping from within the container of course... but...

---

<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: [7 December 2018 13:40 UTC](https://discourse.nodered.org/t/connection-lost-node-red-snap/1683/17 "2018-12-07T13:40:58Z")

</div>

OK - now have some magic...  
Apparently you need to manually attach the network-observe interface and then it will work...  
It won't allow auto-connect as it is considered a management interface)

```
sudo snap connect node-red:network-observe
```

---

<div class="post-metadata">

### Author: ![ceejm1](https://avatars.discourse-cdn.com/v4/letter/c/53a042/32.png) [@ceejm1](https://discourse.nodered.org/u/ceejm1)
#### Post date: [8 December 2018 15:57 UTC](https://discourse.nodered.org/t/connection-lost-node-red-snap/1683/18 "2018-12-08T15:57:36Z")

</div>

Thanks for your help on this and the speedy resolve to the snap issue.

I had uninstalled and re-installed 'normally' before I saw this so all is working well now.

Thanks  
James

---

<div class="post-metadata">

### Author: ![Marooned](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/marooned/32/2858_2.png) [@Marooned](https://discourse.nodered.org/u/Marooned)
#### Post date: [10 December 2018 10:22 UTC](https://discourse.nodered.org/t/connection-lost-node-red-snap/1683/19 "2018-12-10T10:22:58Z")

</div>

Is it the same issue I mentioned [here](https://discourse.nodered.org/t/keeping-the-dashboard-alive/5248/24)?
