[xiaomi_gateway] Unknown gateway

Hi
I have two Xiaomi gateways that were working fine up t the point I upgraded to HA 0.68. Since them I am not able to detect the second gateway and receive the erro
[xiaomi_gateway] Unknown gateway ip 192.168.0.179

the config I use is this
xiaomi_aqara:
discovery_retry: 10
gateways:
- mac: 7811dc64ea23
key: ACE7568C0CFF4539
- mac: 7811dcb35715
key: 843D477EE9004B17

Which has worked fine upto the upgrade to 0.68
I have confirmed that the gateways are up and that sensors attached to them are working fine vi th mihomeApp so it must be a HA issue

same problem here. I can’t find a solution

i added “host: xxx.xxx.x.xxx” for every gateways and now it works

Hi,
Is this how you configured it. It is still not working for me.

xiaomi_aqara:
  discovery_retry: 10
  gateways:
    - mac: 7811dc64ea23
      key: ACE7568C0CFF4539
      host: 192.168.0.180
    - mac: 7811dcb35715
      key: 843D477EE9004B17
      host: 192.168.0.179

By the way the first one of the gateways works fine, it is the second one it can’t connect to. I can see devices talking to the second gateway through the mihome app. I have checked the key and it is right

try regenerating the LAN Key in miapp and use android if possible, had a few issues with using the IOS app.
i had the same issue after a firmware update to the gateways recently
Also confirm the IP address is correct, you never know it could be something as simple as that

Hi,
just recently I experienced similar issue, but after short investigation I found out that Wireless communication protocol of Gateway (found in MiHome app) was off and I needed to enable it generate new “Key”.
I don’t know what caused it … It was working ok and after upgrade to 0.69 it stopped …

yes, that’s works for me.

I regenerated the key and checked the wireless setting and all OK. Checked the the IP address all OK, but noticed the mac address shown in the MiHome App was all caps. So changed the mac address in the config.yaml to all caps and it fixed the issue.
Not sure if this was a result of the gateway firmware update, or a change in HA.

thanks for your help

I have a gateway, 2 Yeelights, 1 Doorsensor, 1 Switch, 1 Motion sensor.
I try to always update Hassio to most recent version.
Currently running v0.75.3

All of a sudden got a couple of errors, related to the gateway:
2018-04-21 18:37:04 ERROR (SyncWorker_10) [xiaomi_gateway] No data in response from hub None
2018-04-21 18:37:14 ERROR (SyncWorker_10) [xiaomi_gateway] Cannot connect to Gateway
2018-04-21 18:37:54 ERROR (SyncWorker_10) [xiaomi_gateway] Got error element in data {“error”:“No device”}

Strange was that all sensors kept working.
I could still turn on the light of the gateway and so forth.
Only error i got was on the switch, it wouldn’t respond.

automation:

  - alias: Doorbell
    id: 'doorbell'
    trigger:
      platform: event
      event_type: click
      event_data:
        entity_id: binary_sensor.switch_158d0002132af5
        click_type: single
    action:
      - service: xiaomi_aqara.play_ringtone
        data:
          gw_mac: !secret gateway_mac
          ringtone_id: 10002
          ringtone_vol: 20
      - service: script.flash_gateway_repeat
      - service: notify.rickmyrna
        data:
          message: "Deurbel!"

It’s the only connected device which references the mac address.

For me the solution was as simple as putting the gateway Mac in Caps.
Example, gateway_mac: 7341DCB6C9XX

I am with the same problem someone else would have something that can be done because all the steps shown above have already been done.