Network problem ? Can't update or install add-on

Hi,

First of all thanks for the amazing job, everything was simple to set up and worked properly the first time… until I tried to patch zigbee addon :stuck_out_tongue:

The patch failed, and the gateway removed the addon completly. And now it’s impossible to install the addon again. Same thing to patch the gateway itself, the page is blank.

I found those logs :

FetchError: request to https://api.mozilla-iot.org:8443/releases failed, reason: connect ETIMEDOUT 192.168.2.1:8443
    at ClientRequest.<anonymous> (/home/pi/mozilla-iot/gateway/node_modules/node-fetch/lib/index.js:1444:11)
    at emitOne (events.js:116:13)
    at ClientRequest.emit (events.js:211:7)
    at TLSSocket.socketErrorListener (_http_client.js:401:9)
    at emitOne (events.js:116:13)
    at TLSSocket.emit (events.js:211:7)
    at emitErrorNT (internal/streams/destroy.js:66:8)
    at _combinedTickCallback (internal/process/next_tick.js:139:11)
    at process._tickCallback (internal/process/next_tick.js:181:9)
2019-06-29 14:10:17.415 ERROR  : Failed to download add-on: zigbee-adapter
FetchError: request to https://s3-us-west-2.amazonaws.com/mozilla-gateway-addons/zigbee-adapter-0.7.12-linux-arm-v8.tgz failed, reason: connect ETIMEDOUT 192.168.2.1:443
2019-06-29 14:10:32.777 ERROR  : FetchError: request to https://api.mozilla-iot.org:8443/releases failed, reason: connect ETIMEDOUT 192.168.2.1:8443
    at ClientRequest.<anonymous> (/home/pi/mozilla-iot/gateway/node_modules/node-fetch/lib/index.js:1444:11)
    at emitOne (events.js:116:13)
    at ClientRequest.emit (events.js:211:7)
    at TLSSocket.socketErrorListener (_http_client.js:401:9)
    at emitOne (events.js:116:13)
    at TLSSocket.emit (events.js:211:7)
    at emitErrorNT (internal/streams/destroy.js:66:8)
    at _combinedTickCallback (internal/process/next_tick.js:139:11)
    at process._tickCallback (internal/process/next_tick.js:181:9)

And this one :

2019-06-29 12:26:32.104 ERROR  : Failed to download add-on: zigbee-adapter
FetchError: request to https://s3-us-west-2.amazonaws.com/mozilla-gateway-addons/zigbee-adapter-0.7.12-linux-arm-v8.tgz failed, reason: connect ETIMEDOUT 192.168.2.1:443
2019-06-29 12:28:29.862 ERROR  : Failed to download add-on: zigbee-adapter
FetchError: request to https://s3-us-west-2.amazonaws.com/mozilla-gateway-addons/zigbee-adapter-0.7.12-linux-arm-v8.tgz failed, reason: connect ETIMEDOUT 192.168.2.1:443

I’ve this NetworkError when attempting to fetch resource in Firefox console.

So I start a ssh connection to the raspberry and try to wget https://s3-us-west-2.amazonaws.com/mozilla-gateway-addons/zigbee-adapter-0.7.12-linux-arm-v8.tgz and this resulted to a timeout to. (It works on my main computer)

I’m wondering if the 192.168.2.1 is the good IP ?

It seems like the raspberry doesn’t have internet connection ??

I didn’t tweak or touch anything until this error.

I tried in LAN and WAN… but with iwconfig I’ve got this :

lo        no wireless extensions.
eth0      no wireless extensions.

where wlan0 seems to be ok (good ESSID etc.)

I tried to change ip in wifi object in /gateway/config/default.js file too :frowning: no success so far.

I tried to shut down wifi and use only LAN. No success.

What’s wrong ?
And bonus question :

  • how to install manually this zigbee addon ? (to make this work and take care of the internet problem later).
  • how to make a clean install without losing rules and things configured ?

Thanks !!!

Hmm… That’s very strange. It seems like your Raspberry Pi may have reverted to captive portal mode. Is there a WebThings Gateway wireless network that you can connect to with your phone or computer?

By the way, patching the gateway on the Pi will not really do anything unless you do some extra work. By default, it just runs a webpack-ed version of the gateway, so it won’t touch the modified source.

Thanks for your reply :slight_smile: Ok I understand now a little bit better.

No, no WebThings Gateway wireless network.

Anyway, I reinstalled it again and it works fine now…

Ok for the tips about the webpacked version :slight_smile:

To answer to myself : to install an addon manually, it’s inside ~/.mozilla-iot :slight_smile: