502 Bad Gateway Zigbee2mqtt

I am having an issue with running zigbee2mqtt ill send a picture of my config

Socat:
enabled: false
master: pty,raw,echo=0,link=/tmp/ttyZ2M,mode=777
slave: tcp-listen:8485,keepalive,nodelay,reuseaddr,keepidle=1,keepintvl=1,keepcnt=5
options: “-d -d”
log: false

MQTT
mqtt:
server: mqtt://core-mosquitto:1883
user: mqtt_user
password: mqtt_password

Server
port: >-
/dev/serial/by-id/usb-ITead_Sonoff_Zigbee_3.0_USB_Dongle_Plus_309db67dce6bef1191589fadc169b110-if00-port0
adapter:

If itneeds fixed please fix it im stuck

The adapter field is empty. You need to specify the correct adapter.

socat:
  enabled: false  
  master: pty,raw,echo=0,link=/tmp/ttyZ2M,mode=777
  slave: tcp-listen:8485,keepalive,nodelay,reuseaddr,keepidle=1,keepintvl=1,keepcnt=5
  options: "-d -d"
  log: false

mqtt:
  server: mqtt://core-mosquitto:1883
  user: mqtt_user
  password: mqtt_password

serial:
  port: "/dev/serial/by-id/usb-ITead_Sonoff_Zigbee_3.0_USB_Dongle_Plus_309db67dce6bef1191589fadc169b110-if00-port0"
  adapter: zstack

Still dosent work

It didn’t start z2m for some reason. You should check logs to see why z2m didn’t start.

My full Zigbee2mqtt configuration - ConBee II coordinator

data_path: /config/zigbee2mqtt
socat:
  enabled: false
  master: pty,raw,echo=0,link=/tmp/ttyZ2M,mode=777
  slave: tcp-listen:8486,keepalive,nodelay,reuseaddr,keepidle=1,keepintvl=1,keepcnt=5
  options: "-d -d"
  log: true
mqtt:
  base_topic: zigbee2mqtt
  server: mqtt://192.168.68.184
  user: mqtt
  password: mqtt
serial:
  port: >-
    /dev/serial/by-id/usb-dresden_elektronik_ingenieurtechnik_GmbH_ConBee_II_DE2124565-if00
  adapter: deconz
external_converters: []
devices: devices.yaml
groups: groups.yaml
homeassistant: true
permit_join: false
advanced:
  log_level: info
  pan_id: 6754
  channel: 11
  network_key:
    - 1
    - 3
    - 5
    - 7
    - 9
    - 11
    - 13
    - 15
    - 0
    - 2
    - 4
    - 6
    - 8
    - 10
    - 12
    - 13
  availability_blocklist: []
  availability_passlist: []
  elapsed: true
  last_seen: ISO_8601_local
device_options: {}
blocklist: []
passlist: []
queue: {}
frontend:
  port: 8099
experimental: {}
availability: false

/

Please post the full log, not just an excerpt.

Cant send it the website crashes

The logs are stored in the zigbee2mqtt folder.

I know but how do i upload files to home assistant community because if i coppy and paste the website crashes

:thinking:

1 Like

As I saw you have more than one error

z2m: Error: Failed to connect to the adapter

So that is probably your issue.

How do i fix that

From the CLI: What is

ls -l /dev/serial/by-id

exactly telling?

Additionally: How did you connect the coordinator to the HA server? Is there an USB-extension cord between the HA server and the coordinator?

Did you lately try to upgrade the coordinator’s firmware?

Also please copy/paste Z2M’s full configuration file you have set so far here. Make sure to format it correctly:

Do you have the Zigbee Home Automation integration installed?

Yes i have

You can’t run both ZHA and Z2M against the same coordinator. Remove ZHA (I assume you don’t have two coordinators) and you should be good.

I removed it and still no luck

data_path: /config/zigbee2mqtt
socat:
enabled: false
master: pty,raw,echo=0,link=/tmp/ttyZ2M,mode=777
slave: tcp-listen:8486,keepalive,nodelay,reuseaddr,keepidle=1,keepintvl=1,keepcnt=5
options: “-d -d”
log: true
mqtt:
base_topic: zigbee2mqtt
server: mqtt://192.168.68.184
user: mqtt
password: mqtt
serial:
port: >-
/dev/serial/by-id/usb-dresden_elektronik_ingenieurtechnik_GmbH_ConBee_II_DE2124565-if00
adapter: deconz
external_converters:
devices: devices.yaml
groups: groups.yaml
homeassistant: true
permit_join: false
advanced:
log_level: info
pan_id: 6754
channel: 11
network_key:
- 1
- 3
- 5
- 7
- 9
- 11
- 13
- 15
- 0
- 2
- 4
- 6
- 8
- 10
- 12
- 13
availability_blocklist:
availability_passlist:
elapsed: true
last_seen: ISO_8601_local
device_options: {}
blocklist:
passlist:
queue: {}
frontend:
port: 8099
experimental: {}
availability: false