Zigbee2MQTT fail after migration

So, basically after trying to migrate from the old Z2MQTT repository to the new one following the instructions that were posted, I am not able to connect to my old devices.

EDIT: Initial issue fixed, now having new issue: Zigbee2MQTT fail after migration - #4 by Hass10

Here is my config:
Current version: 1.21.1-1

data_path: /config/zigbee2mqtt
external_converters: []
devices: devices.yaml
groups: groups.yaml
homeassistant: true
permit_join: false
mqtt:
  base_topic: zigbee2mqtt
  server: mqtt://192.168.1.111:1883
  user: yyyy
  password: xxxx
serial:
  port: /dev/ttyACM0
  adapter: deconz
advanced:
  log_level: debug
  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: []
device_options: {}
blocklist: []
passlist: []
queue: {}
frontend:
  port: 8099
experimental: {}
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

And an example of the log:

Zigbee2MQTT:debug 2021-09-12 19:39:04: Received MQTT message on 'homeassistant/light/0x086aa1ffff5d1234/light/config' with data '{"availability":[{"topic":"zigbee2mqtt/bridge/state"}],"brightness":true,"brightness_scale":254,"command_topic":"zigbee2mqtt/Dining Room Lights/set","device":{"identifiers":["zigbee2mqtt_0x086aa1ffff5d1234"],"manufacturer":"Nue / 3A","model":"Smart dimmer wall switch (HGZB-04D / HGZB-4D-UK)","name":"Dining Room Lights","sw_version":"Zigbee2MQTT 1.21.1"},"json_attributes_topic":"zigbee2mqtt/Dining Room Lights","name":"Dining Room Lights","schema":"json","state_topic":"zigbee2mqtt/Dining Room Lights","unique_id":"0x086aa1ffff5d1234_light_zigbee2mqtt"}'

Zigbee2MQTT:debug 2021-09-12 19:39:04: Received MQTT message on 'homeassistant/sensor/0x086aa1ffff5d1234/linkquality/config' with data '{"availability":[{"topic":"zigbee2mqtt/bridge/state"}],"device":{"identifiers":["zigbee2mqtt_0x086aa1ffff5d1234"],"manufacturer":"Nue / 3A","model":"Smart dimmer wall switch (HGZB-04D / HGZB-4D-UK)","name":"Dining Room Lights","sw_version":"Zigbee2MQTT 1.21.1"},"enabled_by_default":false,"icon":"mdi:signal","json_attributes_topic":"zigbee2mqtt/Dining Room Lights","name":"Dining Room Lights linkquality","state_class":"measurement","state_topic":"zigbee2mqtt/Dining Room Lights","unique_id":"0x086aa1ffff5d1234_linkquality_zigbee2mqtt","unit_of_measurement":"lqi","value_template":"{{ value_json.linkquality }}"}'

Zigbee2MQTT:debug 2021-09-12 19:39:17: Received MQTT message on 'zigbee2mqtt/Dining Room Lights/set' with data '{"state":"OFF"}'

Zigbee2MQTT:debug 2021-09-12 19:39:17: Publishing 'set' 'state' to 'Dining Room Lights'

Zigbee2MQTT:debug 2021-09-12 19:39:21: Received MQTT message on 'zigbee2mqtt/Dining Room Lights/set' with data '{"state":"OFF"}'

Zigbee2MQTT:debug 2021-09-12 19:39:21: Publishing 'set' 'state' to 'Dining Room Lights'

Zigbee2MQTT:info 2021-09-12 19:39:34: MQTT publish: topic 'zigbee2mqtt/Dining Room Lights', payload

I’m not sure if this matters, but my previous instance I had them aligned to “advanced: channel: 18” but when I do that, the front end won’t even load and I get the following error: “Loading devices takes too long time. Consider reading documentation”

It sure does. Changing Zigbee channel requires re-pairing devices !

In my original Z2M I had it set to channel 18. Now, if I set the migrated (new) config to Channel 18 then it gets stuck loading devices.

What did I do wrong?

As you can see from the logs, I can receive updates on the state when changing it manually, but I can’t post/push states from Zigbee.

EDIT:

I changed it to channel 18 and waited about 10minutes for the WebUI to work properly, and it’s now working much better (I can see LQI at least).

However, getting some random success in using commands to turn on/off still, can you check below logs?

## SUCCESFUL at turning light on from Home Assistant
Zigbee2MQTT:debug 2021-09-12 22:30:08: Received MQTT message on 'zigbee2mqtt/Living Room Back Lights/set' with data '{"state": "ON"}'
Zigbee2MQTT:debug 2021-09-12 22:30:08: Publishing 'set' 'state' to 'Living Room Back Lights'
Zigbee2MQTT:info  2021-09-12 22:30:09: MQTT publish: topic 'zigbee2mqtt/Living Room Back Lights', payload '{"brightness":20,"linkquality":231,"state":"ON"}'
Zigbee2MQTT:debug 2021-09-12 22:30:09: Received Zigbee message from 'Living Room Back Lights', type 'attributeReport', cluster 'genOnOff', data '{"onOff":1}' from endpoint 1 with groupID null
Zigbee2MQTT:info  2021-09-12 22:30:09: MQTT publish: topic 'zigbee2mqtt/Living Room Back Lights', payload '{"brightness":20,"linkquality":231,"state":"ON"}'

## FAILED at turning light off from Home Assistant
Zigbee2MQTT:error 2021-09-12 22:30:21: Publish 'set' 'state' to 'Living Room Back Lights' failed: 'Error: Command 0x086bd7ffff6ae77a/1 genOnOff.on({}, {"sendWhenActive":false,"timeout":10000,"disableResponse":false,"disableRecovery":false,"disableDefaultResponse":false,"direction":0,"srcEndpoint":null,"reservedBits":0,"manufacturerCode":null,"transactionSequenceNumber":null,"writeUndiv":false}) failed (no response received)'
Zigbee2MQTT:debug 2021-09-12 22:30:21: Error: Command 0x086bd7ffff6ae77a/1 genOnOff.on({}, {"sendWhenActive":false,"timeout":10000,"disableResponse":false,"disableRecovery":false,"disableDefaultResponse":false,"direction":0,"srcEndpoint":null,"reservedBits":0,"manufacturerCode":null,"transactionSequenceNumber":null,"writeUndiv":false}) failed (no response received)
    at DeconzAdapter.sendZclFrameToEndpoint (/app/node_modules/zigbee-herdsman/src/adapter/deconz/adapter/deconzAdapter.ts:645:23)
    at Endpoint.command (/app/node_modules/zigbee-herdsman/src/controller/model/endpoint.ts:705:28)
    at Object.convertSet (/app/node_modules/zigbee-herdsman-converters/converters/toZigbee.js:272:17)
    at Object.convertSet (/app/node_modules/zigbee-herdsman-converters/converters/toZigbee.js:840:40)
    at EntityPublish.onMQTTMessage (/app/lib/extension/publish.js:230:36)
    at Controller.callExtensionMethod (/app/lib/controller.js:412:58)
Zigbee2MQTT:info  2021-09-12 22:30:21: MQTT publish: topic 'zigbee2mqtt/bridge/log', payload '{"message":"Publish 'set' 'state' to 'Living Room Back Lights' failed: 'Error: Command 0x086bd7ffff6ae77a/1 genOnOff.on({}, {\"sendWhenActive\":false,\"timeout\":10000,\"disableResponse\":false,\"disableRecovery\":false,\"disableDefaultResponse\":false,\"direction\":0,\"srcEndpoint\":null,\"reservedBits\":0,\"manufacturerCode\":null,\"transactionSequenceNumber\":null,\"writeUndiv\":false}) failed (no response received)'","meta":{"friendly_name":"Living Room Back Lights"},"type":"zigbee_publish_error"}'

Hoping the solution not to re-pair as most these devices are behind wall plates.

I tried power cycling all (from switchboard) and also rebooting via WebGUI as per https://github.com/Koenkk/zigbee2mqtt/issues/8234#issuecomment-892137180

No luck still…

UPDATE: Finally got it working after updating the Firmware on my Conbee II stick (something I forgot was a thing). You can follow these steps here if you need to also.

1 Like