Why does the HomeKit connection failed with openHAB although I can find my instance in the Home app?

I am going to use HomeKit with my AVM FRITZ!DECT 200 devices to measure the temperature and to toggle some bulbs.

Therefore I took a raspberry pi and installed the latest image of openHABian until I had a running version of openHAB (2.3.0) with the latest updates.

Next step was to install AVM FRITZ!Box Binding and connecting my Fritz!Box and all other things to create items. Everything worked well, I am able to toggle my bulbs with the openHAB iOS app. So far so good.

Then I continued with the HomeKit Integration as described here. That part went well, too, I can still toggle my items with the openHAB iOS app.

The trouble started when I tried to do the pairing in the iOS Home app.

  1. First of all I can detect my instance

  2. After entering the PIN pairing starts

  3. After a while pairing failed
    openHAB_paring_failed

  4. My logs look like this:
    2018-12-04 21:15:38.066 [INFO ] [basic.internal.servlet.WebAppServlet] - Started Basic UI at /basicui/app
    2018-12-04 21:15:41.379 [INFO ] [arthome.ui.paper.internal.PaperUIApp] - Started Paper UI at /paperui
    2018-12-04 21:15:43.098 [INFO ] [com.beowulfe.hap.HomekitRoot ] - Added accessory openHABian
    2018-12-04 21:15:50.275 [INFO ] [com.beowulfe.hap.HomekitRoot ] - Added accessory Licht Wohnzimmer
    2018-12-04 21:15:50.314 [INFO ] [pl.http.impl.NettyHomekitHttpService] - Bound homekit listener to /0:0:0:0:0:0:0:0:9124
    2018-12-04 21:15:50.453 [INFO ] [ap.impl.jmdns.JmdnsHomekitAdvertiser] - Advertising accessory openHABian
    2018-12-04 21:15:50.479 [INFO ] [ap.impl.jmdns.JmdnsHomekitAdvertiser] - Registering _hap._tcp.local. on port 9124
    2018-12-04 21:15:50.458 [INFO ] [pl.http.impl.NettyHomekitHttpService] - Resetting connections
    2018-12-04 21:15:50.618 [INFO ] [com.beowulfe.hap.HomekitRoot ] - Added accessory Temperatur Wohnzimmer
    2018-12-04 21:15:50.687 [INFO ] [pl.http.impl.NettyHomekitHttpService] - Resetting connections
    2018-12-04 21:15:50.706 [INFO ] [com.beowulfe.hap.HomekitRoot ] - Added accessory Licht Schlafzimmer
    2018-12-04 21:15:50.750 [INFO ] [pl.http.impl.NettyHomekitHttpService] - Resetting connections
    2018-12-04 21:15:50.769 [INFO ] [com.beowulfe.hap.HomekitRoot ] - Added accessory Temperatur Schlafzimmer
    2018-12-04 21:15:50.817 [INFO ] [pl.http.impl.NettyHomekitHttpService] - Resetting connections
    2018-12-04 21:15:50.837 [INFO ] [com.beowulfe.hap.HomekitRoot ] - Added accessory Licht Kinderzimmer
    2018-12-04 21:15:50.933 [INFO ] [pl.http.impl.NettyHomekitHttpService] - Resetting connections
    2018-12-04 21:15:50.962 [INFO ] [com.beowulfe.hap.HomekitRoot ] - Added accessory Temperatur Kinderzimmer
    2018-12-04 21:15:51.019 [INFO ] [pl.http.impl.NettyHomekitHttpService] - Resetting connections
    2018-12-04 21:15:51.039 [INFO ] [com.beowulfe.hap.HomekitRoot ] - Added accessory Licht Dachboden
    2018-12-04 21:15:51.104 [INFO ] [pl.http.impl.NettyHomekitHttpService] - Resetting connections
    2018-12-04 21:15:51.134 [INFO ] [com.beowulfe.hap.HomekitRoot ] - Added accessory Temperatur Dachboden
    2018-12-04 21:15:51.232 [INFO ] [pl.http.impl.NettyHomekitHttpService] - Resetting connections
    2018-12-04 21:15:51.253 [INFO ] [com.beowulfe.hap.HomekitRoot ] - Added accessory Licht Gallerie
    2018-12-04 21:15:51.355 [INFO ] [pl.http.impl.NettyHomekitHttpService] - Resetting connections
    2018-12-04 21:15:51.390 [INFO ] [com.beowulfe.hap.HomekitRoot ] - Added accessory Temperatur Gallerie
    2018-12-04 21:15:51.583 [INFO ] [pl.http.impl.NettyHomekitHttpService] - Resetting connections
    2018-12-04 21:15:52.384 [INFO ] [com.beowulfe.hap.HomekitRoot ] - Added accessory Licht Gaestezimmer
    2018-12-04 21:15:52.741 [INFO ] [pl.http.impl.NettyHomekitHttpService] - Resetting connections
    2018-12-04 21:15:52.790 [INFO ] [com.beowulfe.hap.HomekitRoot ] - Added accessory Temperatur Gaestezimmer
    2018-12-04 21:15:52.949 [INFO ] [pl.http.impl.NettyHomekitHttpService] - Resetting connections
    2018-12-04 21:15:53.663 [INFO ] [panel.internal.HABPanelDashboardTile] - Started HABPanel at /habpanel

I cannot find any helpful error message in the logs and I also saw this post. But I think the difference is, that I can find my openHAB instance and I can start the pairing process. This is why I think this is not a firewall issue to establish the connection. My device is also connected via LAN not via WIFI.

Does anybody have an idea how to trace the issue to fix it?

I’ve had the same experience today with 2.4 M7.

Any idea how to push the issue forward? I’d like to be a contributing player.

Same issue after upgrade to openHAB (2.4.0). Any news about it?

Finally I fixed it. I checked the documentation again and found this section:

openHAB HomeKit hub shows up when I manually scan for devices, but Home app reports “can’t connect to device”
If you see this error in the Home app, and don’t see any log messages, it could be because your IP address in the networkInterface setting is misconfigured. The openHAB HomeKit hub is advertised via mDNS. If you register an IP address that isn’t reachable from your phone (such as localhost , 0.0.0.0 , 127.0.0.1 , etc.), then Home will be unable to reach openHAB.

I am not sure since when this section is there, but after setting the IP in the field networkInterface pairing was successful. I am relatively sure that I have never filled this field in older installations with version 2.2.0 and still the pairing worked. However problem solved.