Node-red connection lost in google chrome

Hello my node-red installation started to fail with google chrome. Every 5 second show the messa "connection Lost". I started to work 7 months ago normally and two day ago started to fail.

I have instaled node-red 1.0.3 version in an open susse machine.

Hi Damian, welcome to the forum.
Are you 'losing connection' or is there a problem causing node-RED to continually reboot?
Can you check the node-RED log, to see what is happening.

Try flushing your browser cache.

Good morning, the meesage of node-red is "connection-lost". And is only with google chrome. With Microsoft Edge are working.. I have the error log under PM2 and i dont have error message...I think is a problem of some acutalization of google chrome. Maybe a sevurity because off HTTPS i dont know

Try flushing your browser cache.

Edje11 I did the flushing of the browse cahe but the problem continue. :frowning:

What errors (if any) are showing in the Chrome browser developers console (press F12). That should give you a clue what's happening.

Paul i dont have error at the console of chrome only that messages every time that the page are refreshing
image

I am getting connection lost message in chrome when one of my node-red nodes is busy for several seconds. This you can check by monitoring the CPU of the machine running node-red. If it is 100% (or 25% in case your machine has 4 CPU threads like a raspberry pi 3B) then this might be the cause of your problem.

Before checking the CPU, I would first check the node-red log file.

I do recognize the disconnections with high CPU or nodes that take extended time. For me I traced it back to several graphs I had on my dashboard. Overtime these graphs accumulated many (many, many) data points which I also restored with a persistent node. As some point in time the number of disconnects when up and dashboard load time increase dramatically.

First test I did was clear the graph and this immediately resulted into a much more stable dashboard.

And yes, looking at the log should always be your next step..... :slight_smile:

1 Like

I think is a problem of the las version of google chrome 83.0.4103.61....

When i refresh the page and start to show the errors the log file of chrome send me

[Deprecation] Application Cache was previously restricted to secure origins only from M70 on but now secure origin use is deprecated and will be removed in M82. Please shift your use case over to Service Workers.
DevTools failed to load SourceMap: Could not load content for http://10.2.5.13:1880/ui/js/angular-chart.min.js.map: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE

which version of dashboard nodes are you using ?

i am using the version 2.20

To be sure of this, you can test with other browser ( I would suggest firefox)

I am also investigating if Chromium trying to (automatically) upgrade may disturb a Node-RED dashboard application. Trying to find out how to disable these annoying upgrade messages too. I already upgraded Chromium a few days ago but the message appeared again today.

This application runs in a Raspberry Pi with the Desktop version of Raspian. It is a kiosk type application. I just added an ui_control node to monitor the connection from the runtime to the dashboard. Perhaps this kind of monitoring can help you too ?

r-02

I see quite a lot of connection lost messages in the debug node.

What I find strange is that the screen is connected directly to the Raspberry Pi that runs the runtime. I can not imagine how come that the websocket between Chromium and the runtime could eventually be lost. There is no way that this can be a network issue.

UPDATE:

10 minutes after relaunch Chromium the connection lost messages are gone. I will keep monitoring. Apparently (initial assumption) is that disconnections occur whenever Chromium displays the upgrade/relaunch warning.

It seems to me there is a workaround for the annoying Chromium upgrade popup:

https://www.raspberrypi.org/forums/viewtopic.php?f=63&t=264399&start=50

Ok Guys i found the problem. In my company the IT guys installed the Kaspersky antivirus and that antivirus generated that problem....no Google, no Node-red, the antivirus.

Do you have any idea what the antivirus does that impacts the connections ? Any plan on how you will circumvent ?