SSH & Web Terminal & zibgbee2mttq both give me a 502 bad gateway error

ZHA works I can see my test aqara temp sensor OK so the hardware sonoff usb dongle works OK. community ssh addo works Ok as well.

The two official modules do not giving a 502 error suggesting maybe a common error problem.

Is there anything that these both are related to?

502 bad gateway is the generic error the front-end fires whenever an add on like that can’t be loaded through ingress. (Add on didn’t start or isn’t displaying properly)

It just means both addons aren’t started - and doesn’t necessarily indicate a common cause. Troubleshoot each - what do your logs say.

not anything that’s helping with googling,

➜ 2022-06-20.22-46-21 more log.txt
info 2022-06-20 22:46:21: Logging to console and directory: ‘/config/zigbee2mqtt/log/2022-06-20.22-46-21’ filename: log.txt
info 2022-06-20 22:46:21: Starting Zigbee2MQTT version 1.25.2 (commit #unknown)
info 2022-06-20 22:46:21: Starting zigbee-herdsman (0.14.34)
error 2022-06-20 22:46:21: Error while starting zigbee-herdsman
error 2022-06-20 22:46:21: Failed to start zigbee
error 2022-06-20 22:46:21: Check Zigbee2MQTT fails to start | Zigbee2MQTT for possible solutions
error 2022-06-20 22:46:21: Exiting…
error 2022-06-20 22:46:21: Error: spawn udevadm ENOENT
at Process.ChildProcess._handle.onexit (node:internal/child_process:283:19)
at onErrorNT (node:internal/child_process:478:16)
at processTicksAndRejections (node:internal/process/task_queues:83:21)
➜ 2022-06-20.22-46-21

➜ zigbee2mqtt more configuration.yaml
homeassistant: true
➜ zigbee2mqtt

just googling and I should see more lines or is one line all that’s expected?

Are you trying to connect to the same coordinator you did with ZHA with zigbee2mqtt? If so, you need to disable / uninstall ZHA first - only one can open the port at a time… did you disable it?

I never enabled it. I did uninstall zigbee2mqtt then configured the sonoff in the webui which I assume enabled ZHA? then a temp sensor popped up in < 1second after I pressed the pair button on it.

So hardware seems good.

My point is you say ZHA is good and works.

Great - Hardware is ok - Fantastic!

Whether YOU enabled ZHA or not - it’s enabled if its working (HA detects and configures if for you - that’s probably where it came from.)

It’s also the issue if you’re trying to install Zigbee2mqtt to use that Sonoff. Which I assume you are, because that log you noted above - a failed start for Zigbee2mqtt. This is expected if you have ZHA operating and try to open the same coordinator - Z2M will fail to start and - you will get a 502 error attempting to open its console.

You can have one or the other - not both, unless you get a second zigbee coordinator stick.

Ok, googling isnt clearly showing me how to disable it and remove it? (I assume remove it?).

I can just delete /config zibgee.db? and reboot ?

You can disable any integration (which ZHA is) by going to System > Devices and Services, locate your integration, then select the vertical elipsis (three dot) menu (blue arrow) and then disable (red arrow) in the popup:
image

Randomly nuking files in HA is never advisable.

1 Like

Ok, I might just re-flash the emmc on the odroid n2+ and start by making sure ZHA is disabled before I do anything else, TY :slight_smile:

The only Q is 2022:5 or 2022:6 or earlier…

Ok clean install and a new error.

8><—
Zigbee2MQTT:error 2022-06-21 16:50:54: Error while starting zigbee-herdsman
Zigbee2MQTT:error 2022-06-21 16:50:54: Failed to start zigbee
Zigbee2MQTT:error 2022-06-21 16:50:54: Check Zigbee2MQTT fails to start | Zigbee2MQTT for possible solutions
Zigbee2MQTT:error 2022-06-21 16:50:54: Exiting…
Zigbee2MQTT:error 2022-06-21 16:50:54: Error: Error while opening serialport ‘Error: Error: I/O error setting custom baud rate of 115200’
8><-------