I am setting up a HASSIO server running on HyperV and trying to connect it to a Xiaomi gateway. For some reason, I just can’t get HASSIO to see the gateway.
I have run Nmap from an Ubuntu machine on the network and see port 9898 open on the gateway for UDP traffic. The Gateway is otherwise looking fine. Likewise, HASSIO is otherwise working fine (albeit it’s not doing much)
Thanks for the advice.
I have tested ports 9898 and 4321 using Nmap. They are open intermittently
It almost seems like when one is open then the other is closed which seems wrong.
Also the app is now complaining that the WiFi signal at the gateway is weak even when it’s next to the WiFi AP.
It’s seeing the sensors ok it seems, but I’m suspicious of the hardware now.
Wdyt?
Many thanks
walaj@JonLabNUC:/home/homeassistant/.homeassistant$ sudo nmap -sU 192.168.1.72 -p 9898,4321
Starting Nmap 7.01 ( https://nmap.org ) at 2019-08-21 09:54 AEST
Nmap scan report for LUMI-GATEWAY-V3_MAIN (192.168.1.72)
Host is up (0.0021s latency).
PORT STATE SERVICE
4321/udp open|filtered rwhois
9898/udp open unknown
MAC Address: 78:11:DC:E1:F8:CD (Unknown)
Nmap done: 1 IP address (1 host up) scanned in 1.59 seconds
I ran it a couple of times, and other than one “no reply”, was open each time.
Hi again
Thanks for the input.
I tried taking out the colons from the MAC address. Unfortunately that didn’t help.
I bought a second gateway in case there was a fault with the first one.
I get exactly the same results.
I will look again at the HASS VM to make sure that there is no filtering on its virtual network port, but last time I asked, my tech guy said no…
If anyone can advise on any further troubleshooting steps, that would be great.
Thank
if lan access is enabled, and the ports show as (mostly) open in nmap, then I’m at a loss.
If the ports were not open, that would the obvious problem - some hubs (Europe version I think) dont support the LAN connection, but that isn’t an issue here). Also, there was a xiamoi firware version that locked the ports if you upgraded BEFORE unlocking…
Thanks for the feedback.
I have now set up a fresh instance of HASSIO on a brand new Pi 4 and still no luck.
I have two gateways. They are both new and they are both running firmware 1.4.1.170. They both have LAN mode turned on in the Mi Home app using the special menu.
They are connected to the network fine and I can ping them both.
Please note, there are two versions of the hub: v1 and v2. v1 can be used with Home Assistant without any problems, however, v2 might be less straight forward when it comes to enabling the local API, and might even require you to open up your device in order to do so. Xiaomi has suggested this is in the pipeline.
I am wondering if this might be my problem somehow. The guide also says
If your gateway’s MAC address starts with 04:CF:8C, there is a good chance that the required port 9898 is closed on your gateway (you can check it with the Nmap utility, using the command sudo nmap - sU {gateway_ip} -p 9898). To fix that issue, you need to do these steps:
Then lists a pretty horrible set of steps.
And both my gateways’ MAC addresses do start with those 6 digits
I am hoping very much to avoid having to do those steps. Soldering is not my think at all!!
Hi again
I got a colleague to do the necessary soldering and console config and the Xiaomi gateway and sensors are now visible in HASSIO!
Thanks very much for everyone’s help