Cannot start Node-Red - HASSIO on Ubuntu - ENOTFOUND

Hi All!

My HASSIO install and Node-Red environments have been working fine - no problems.

About 3 weeks ago, I added Pi-Hole and even then - aside from other networking issues everything worked fine with HASSIO/Node-Red, no issues.

Today I noticed that my Node-Red automations were’nt running. Upon digging in HASSIO and the Node-Red addon page, Node-Red was not running.

When I tried running it, the error lines below were in logs.

Log
[INFO] Disabling SSL
[INFO] Updating IDE Users
[INFO] Adding IDE User admin
[INFO] Updating HTTP Node User
[INFO] Adding HTTP Node User admin
[INFO] Disabling Projects
[INFO] Attempting to install/update nodes: node-red-contrib-home-assistant
npm ERR! code ENOTFOUND
npm ERR! errno ENOTFOUND
npm ERR! network request to https://registry.npmjs.org/node-red-contrib-home-assistant failed, reason: getaddrinfo ENOTFOUND registry.npmjs.org registry.npmjs.org:443
npm ERR! network This is a problem related to network connectivity.
npm ERR! network In most cases you are behind a proxy or have bad network settings.
npm ERR! network 
npm ERR! network If you are behind a proxy, please make sure that the
npm ERR! network 'proxy' config is set properly.  See: 'npm help config'

npm ERR! A complete log of this run can be found in:
npm ERR!     /root/.npm/_logs/2018-07-22T22_02_15_575Z-debug.log
[ERROR] Can't install nodes!

So I jumped onto my HASSIO box via SSH. I’m running HASSIO on Ubuntu, so I double-checked DNS and made sure I could reach the address registry.npmjs.org and I can with no issues. I can ping it as well.

After doing some research, it appears that maybe HASSIO - the docker might not be using the same DNS as configured in my Ubuntu /etc/resolv.conf and that my testing is on the host/Ubuntu side, not the HASSIO side.

I ran into this page from another page here on the forums: https://docs.resin.io/reference/resinOS/network/2.x/

But when I tried accessing the docker image, I get the error that 27e642c6/amd64-addon-nodered is not running.

At this point, I’m not sure what the problem is and I’m not sure how to test or make the necessary changes to affect the HASSIO network aspects.

Help! How do I get Node-Red started and running again?

Edit: I can see the requests to the registry.npmjs.org are allowed with no issues. I didn’t have to whitelist anything.

Ok - so not a single change, reboot, update or anything made and the following happens when I issued a “start” of Node-Red from HASSIO

[INFO] Disabling SSL
[INFO] Updating IDE Users
[INFO] Adding IDE User admin
[INFO] Updating HTTP Node User
[INFO] Adding HTTP Node User admin
[INFO] Disabling Projects
[INFO] Attempting to install/update nodes: node-red-contrib-home-assistant
npm WARN [email protected] No repository field.
npm WARN [email protected] No license field.


> [email protected] start /usr/src/node-red
> node $NODE_OPTIONS node_modules/node-red/red.js -v $FLOWS "--userDir" "/share/node-red"

23 Jul 16:02:24 - [info] 

Welcome to Node-RED
===================

23 Jul 16:02:24 - [info] Node-RED version: v0.18.7
23 Jul 16:02:24 - [info] Node.js  version: v8.11.2
23 Jul 16:02:24 - [info] Linux 4.4.0-87-generic x64 LE
23 Jul 16:02:25 - [info] Loading palette nodes
23 Jul 16:02:53 - [info] Dashboard version 2.7.0 started at /ui

How is this possible? What prevented this from working yesterday?

Happy it’s working, but I’m never happy to know the root cause :thinking::frowning_face:

This may not help, but in another thread @frenck mentioned that a new Hassio Supervisor was in beta.

Another Node-Red thread with possible solution

I could not get Node-Red to open on my setup, but after loading the new beta supervisor it seems to be working okay.

1 Like

Thanks for the details. I checked the link. Seems that 115 works and 117 broke it. But, I’ve been on 115.

Hass.io supervisor
Version	115
Latest version	115

Very strange… Guess I’ll keep up on this and keep an eye on things.

Mine died with 115, was resurrected with 118 beta. But I am on a RPi 3.

Yes, I am not aware of the release schedule. I would take a snapshot to allow going back to the current setup just in case.

1 Like

Currently supervisor 118 is already available for stable (https://s3.amazonaws.com/hassio-version/stable.json) but some users are still having (other) issues.

1 Like

Good idea! Backup completed. Thanks.

But on the beta channel, not stable - right?

I’m showing current, but I’m on the stable channel, not the beta.

Ah! Maybe that has something to do with it.

So you joined beta and 118 fixed it for you?

It did I have not tried it this morning and have a doctors appointment that have to go to. I also am using my ip address for url.

Cool - well thanks for your help!