Xiaomi Gateway (Aqara) integration loss connection to zigbee subdevices every few hours and they become unavailable.
See original GitHub issueThe problem
Xiaomi Gateway (Aqara)integration loss connection to zigbee subdevices every few hours and they become unavailable. Effected devices: Motion sensors Temperature sensors Vibration sensors Switches etc…
The devices are still available and working on “xiaomi home” app and the temperature sensors still available and working with “xiaomi miio” integration in home assistant. Reload the integration or restart home assistant solve the issue for few hours then it happens again.
What version of Home Assistant Core has the issue?
core-2021.12.10
What was the last working version of Home Assistant Core?
No response
What type of installation are you running?
Home Assistant OS
Integration causing the issue
Xiaomi Gateway (Aqara)
Link to integration documentation on our website
https://www.home-assistant.io/integrations/xiaomi_aqara/
Example YAML snippet
No response
Anything in the logs that might be useful for us?
Maybe:
Logger: xiaomi_gateway
Source: /usr/local/lib/python3.9/site-packages/xiaomi_gateway/__init__.py:333
First occurred: January 27, 2022, 12:14:51 PM (3 occurrences)
Last logged: January 28, 2022, 9:09:02 AM
Cannot connect to Gateway
and:
Logger: xiaomi_gateway
Source: /usr/local/lib/python3.9/site-packages/xiaomi_gateway/__init__.py:429
First occurred: January 27, 2022, 12:14:51 PM (3 occurrences)
Last logged: January 28, 2022, 9:09:02 AM
No data in response from hub None
Additional information
While the issue happens The devices are still available and working on “xiaomi home” app and the temperature sensors still available and working with “xiaomi miio” integration in home assistant.
Issue Analytics
- State:
- Created 2 years ago
- Comments:29 (8 by maintainers)

Top Related StackOverflow Question
Thank you for a tip - it was connected with docker service upgrade (changed docker-compose structure). In newer version it wasn’t possible to add
network_mode: hostandportsdeclaration in the same service in docker-compose file. I decided to use theportssection and I didn’t connect that with integration problems. As you suggested, I noticed that this setting prevents receiving multicast traffic. I changedportssection tonetwork_mode: hostand my integration is stable again. Thank you @syssi@llapinski It looks like your setup / Home Assistant instance isn’t able to receive multicast traffic.