YoLink broken after 2024.1.4 update

I had to downgrade to 2024.1.2 for Yolink to start working again…

My Yolink integration stopped working too. I’m not sure when. I’m running at 2024.1.5. I troubleshot a motion sensor today, that is when I noticed Yolink was down. I reloaded the integration and the Yolink sensors will update their state in HA. But if a sensor changes state there after HA will not see the state change. My maybe go back to 2024.1.3. Some of my more helpful automation use Yolink. Its late now. This forum can be time time saver.

Yes, you need to downgrade for it work correctly. There is an open issue on Yolink.

Seems to be fixed in 2024.1.6

Working for me in 2024.1.6 as well!! I’d consider this topic closed. Love HA :smiley:

Yolink back up for me with 2024.1.6. :grinning:

Same here - I thinkn the issue is behind us

Wanted to come here first to see if the YoLink issue was taken care of before installing the new update 2024.1.6.
Since I had to roll back to 2024.1.3 just to have everything working again.

Glad to see the issues is fixed now!

1.6 did not fix the problem

Hi,
To troubleshoot the issue even after updating to 2024.1.6, please check the following:

  1. Are the sensors updating properly in YoLink app?
  2. If yes, then please check if the YoLink integration is enabled and reload it.
  3. Please check HA logs to see if MQTT/YoLink related errors are reported.

Hope this helps.

@ramdisk I did notice several of my sensros after some hours were showing ans unavailable, but reloading the integratrion fixed that and they are working now… possibly another issue with the sensors becoming unavailable now? Ugh

I use this and then inspecting it’s attributes in developer → states shows which ones at a glance - pretty handy (although it should be unnecessary):

template:
#
# This binary sensor not only specifies if any entities in the integration are unavailable, but also if
# there are any unavailable, it will contain an attribute that is a list of the entities that are unavailable.
#
  - binary_sensor:
      - name: "Any Yolink Unavailable"
        state: "{{ integration_entities('yolink') | select('is_state', 'unavailable') | list | count > 0 }}"
        attributes:
          entity_id: "{{ integration_entities('yolink') | select('is_state', 'unavailable') | list }}"
        unique_id: any_yolink_unavailable

#
# This binary sensor not only specifies if any entities in the integration are known, but also if
# there are any unknown, it will contain an attribute that is a list of the entities that are unknown.
#
  - binary_sensor:
      - name: "Any Yolink Unknown"
        state: "{{ integration_entities('yolink') | select('is_state', 'unknown') | list | count > 0 }}"
        attributes:
          entity_id: "{{ integration_entities('yolink') | select('is_state', 'unknown') | list }}"
        unique_id: any_yolink_unknown

re-loaed YoLink, cleared my log and I keep getting the following

Logger: yolink.mqtt_client
Source: runner.py:188
First occurred: 4:59:35 PM (8 occurrences)
Last logged: 5:00:45 PM

yolink mqtt client disconnected!

The only reason why I stuck with Yolink for so long was because they were the only integration for Home Assistant that where they call you and if you don’t answer then they call the authorities for whatever specific sensors you prefer. (24/7 service offered by Virtualarm).

The design for their hub is flawed (not local) and then the hub talks to the Yolink’s servers and then home assistant has a connection only to the Yolink servers not the hub at all. The only reason why it is possible to do this with almost no latency (when all connections are up and running) is because Yolink keeps open mqtt connections between their servers and the hub, and home assistant and their servers. I have put the hub on its own vlan on my network with wide open Internet access with minimized latency which has helped a lot. These are the kinds of error messages that are still typically in my log:

Feb  1 05:29:11 kruse-pi homeassistant[1342]: #033[32m2024-02-01 05:29:11.386 INFO (MainThread) [homeassistant.components.yolink.coordinator] Fetching yolink data recovered#033[0m
Feb  1 06:29:41 kruse-pi homeassistant[1342]: #033[31m2024-02-01 06:29:41.827 ERROR (MainThread) [homeassistant.components.yolink.coordinator] Timeout fetching yolink data#033[0m
Feb  1 06:59:42 kruse-pi homeassistant[1342]: #033[32m2024-02-01 06:59:42.016 INFO (MainThread) [homeassistant.components.yolink.coordinator] Fetching yolink data recovered#033[0m
Feb  1 07:56:34 kruse-pi homeassistant[1342]: #033[31m2024-02-01 07:56:34.098 ERROR (MainThread) [yolink.mqtt_client] yolink mqtt client disconnected!#033[0m
Feb  1 08:00:17 kruse-pi homeassistant[1342]: #033[31m2024-02-01 08:00:17.827 ERROR (MainThread) [homeassistant.components.yolink.coordinator] Timeout fetching yolink data#033[0m
Feb  1 08:08:09 kruse-pi homeassistant[1342]: #033[31m2024-02-01 08:08:09.029 ERROR (MainThread) [homeassistant.components.yolink.coordinator] Error fetching yolink data: #033[0m
Feb  1 08:30:18 kruse-pi homeassistant[1342]: #033[32m2024-02-01 08:30:18.257 INFO (MainThread) [homeassistant.components.yolink.coordinator] Fetching yolink data recovered#033[0m
Feb  1 10:29:02 kruse-pi homeassistant[1342]: #033[31m2024-02-01 10:29:02.827 ERROR (MainThread) [homeassistant.components.yolink.coordinator] Timeout fetching yolink data#033[0m
Feb  1 10:59:03 kruse-pi homeassistant[1342]: #033[32m2024-02-01 10:59:03.636 INFO (MainThread) [homeassistant.components.yolink.coordinator] Fetching yolink data recovered#033[0m
Feb  1 10:59:23 kruse-pi homeassistant[1342]: #033[31m2024-02-01 10:59:23.220 ERROR (MainThread) [yolink.mqtt_client] yolink mqtt client disconnected!#033[0m
Feb  1 10:59:41 kruse-pi homeassistant[1342]: #033[31m2024-02-01 10:59:41.827 ERROR (MainThread) [homeassistant.components.yolink.coordinator] Timeout fetching yolink data#033[0m
Feb  1 11:01:22 kruse-pi homeassistant[1342]: #033[31m2024-02-01 11:01:22.827 ERROR (MainThread) [homeassistant.components.yolink.coordinator] Timeout fetching yolink data#033[0m
Feb  1 11:29:42 kruse-pi homeassistant[1342]: #033[32m2024-02-01 11:29:42.018 INFO (MainThread) [homeassistant.components.yolink.coordinator] Fetching yolink data recovered#033[0m
Feb  1 11:31:23 kruse-pi homeassistant[1342]: #033[32m2024-02-01 11:31:23.445 INFO (MainThread) [homeassistant.components.yolink.coordinator] Fetching yolink data recovered#033[0m
Feb  1 11:37:01 kruse-pi homeassistant[1342]: #033[31m2024-02-01 11:37:01.171 ERROR (MainThread) [yolink.mqtt_client] yolink mqtt client disconnected!#033[0m
Feb  1 12:32:43 kruse-pi homeassistant[1342]: #033[31m2024-02-01 12:32:43.827 ERROR (MainThread) [homeassistant.components.yolink.coordinator] Timeout fetching yolink data#033[0m
Feb  1 13:02:44 kruse-pi homeassistant[1342]: #033[32m2024-02-01 13:02:44.546 INFO (MainThread) [homeassistant.components.yolink.coordinator] Fetching yolink data recovered#033[0m
Feb  1 15:48:08 kruse-pi homeassistant[1342]: #033[31m2024-02-01 15:48:08.828 ERROR (MainThread) [homeassistant.components.yolink.coordinator] Timeout fetching yolink data#033[0m
Feb  1 15:48:08 kruse-pi homeassistant[1342]: #033[31m2024-02-01 15:48:08.832 ERROR (MainThread) [homeassistant.components.yolink.coordinator] Timeout fetching yolink data#033[0m
Feb  1 15:53:21 kruse-pi homeassistant[1342]: #033[31m2024-02-01 15:53:21.936 ERROR (MainThread) [homeassistant.components.yolink.coordinator] Timeout fetching yolink data#033[0m

I have had long conversations with the developer about this “yolink mqtt client disconnected” message and is the only one that isn’t big issue… and when that yolink mqtt client is reconnected there is no entry in the log for that (- I believe it tries to reconnect every 20 seconds - which would be better if it was there). If the Yolink hub is forced to connect to the Internet through a vpn that won’t work. I can get more details about what ports it uses and so on but it really just needs an open Internet connection from the hub itself to the outside world.

YoLink is working on a new generation local hub for a long time and who knows how long that will take - and no guarantee it will work with their older sensors… They have no ETA.

I was contacted last week from someone from company called onsitemonitor.com. They offer 24/7 monitoring services and are working to get something set up with Shelly! Now if that becomes available it would be absolutely fantastic - but it looks like their prices are higher than yolink ($9.99/Mo for unlimited devices for Yolink).

So the short term quick answer to solve your problem is to do everything within your power to get rid of that “Yolink MQTT client disconnected” message. Note also I reboot my YoLink hub at least once a month (there is no way to do it programmatically, I had to have it plugged into a smart plug). I have found that after about six months being online it typically goes kablooey and causes all kinds of issues which go away when you cut the power to it and then restore it.

Hope that helps

Wow, you have had quite a bit of experience with YoLink!! I just use like 4 open/close sensors and one motion sensor. Been using them only for 3 months now. The only issue I have seen is that occasionally, the hub goes offline even though it is a wired connection. I do not see client disconnected error. Maybe I just got lucky. Who knows when the luck runs out. So question: when you see these client disconnected errors, do the sensors and any HA automations still work?

Taking cue from your experience, I also connected the hub power supply to a wifi outlet so I can periodically reboot the hub. Thanks for sharing your experiences!!

1 Like

how do you do that?

today(2-2-24) I re-loaded a backup and my Home Assistant Core is 1.3 and all is good so far with YoLink. Fingers crossed

Attention: matrixd2
@KruseLuds, I believe you may hold my answer to the not-so recent failure of the YoLink Integration. Additionally, after a few months of troubleshooting & isolating failure myself, I believe I know the cause & have repeatable results. (I have started from scratch SO Many times :frowning: )
Because I depend on Home Assistant for Medical and Security as well as uncountable benefits, Internet Security is paramount. I use two essential add-ons providing just that:

  1. DuckDNS
  2. NGINX Home Assistant SSL Proxy

At the time of 2024.1.X I was experiencing issues, their tech support assured me it would be fixed on the next update. I worked for a sort time and failed again on a following update. I tried everything, but all of the devices remained “unavailable”. In frustration, I deleted it and tried to reinstall. BIG Failure! No matter what, I had a message that NGINX failed. Only thing was to start over with a new build. After I configured my add-ons I attempted to install. Nope NGINX failure.
Start over again, before addons, I successfully installed YoLink without any issues; however, When I installed the two add-ons, It was immediately broke again and my devices were again “unavailable” .
My conclusion is the integration no longer supports SSL. I was reporting the bug, and it didn’t report correctly :frowning: . Also, My YoLink hub has unrestricted access to the internet on its own external WAN IP without a firewall. Home Assistance is also on its own external WAN IP, with pfSense providing the port forwarding as well as the firewall. It is wonderful to have everything living in VMs of an ESXI server.

SO… Is there anyone that can tell me a method for getting YoLink to operate in a SSL https as well as http ?
Meanwhile, tomorrow I start over again. (I am nearly able to do that in my sleep now :zzz:) Please HELP, anyone?

Matrixd mentioned to me that the MQTT pipe they keep open between HA and their servers does not support SSL. (The Yolink integration uses MQTT under the covers even if you do not have the MQTT inegration installed.)

The Yolink Hub should be have an open path to the internet with a solid fast and reliable connection. I don’t really care if someone on the internet was able to figure out that I opened a window or there was a leak under a sink in my home. Also, is your HA instance connecting to the internet directly or through a VPN service provider? Alot of my problems went away when I stopped connecting HA to the internet through a VPN tunnel.

I got rid of duckdns (because they would have outages) and use the cloudflare integration for external access to HA (does not even require port forwarding at all).

No one method is 100% secure. You either have to pick your poison - or use a combination of things. For internet access for devices in my home (notebooks, ipads, andoroid, iphone etc.) - I use two VPN Service providers whose headquarters are not in any of the 13-eyes countries. I keep 5 open VPN tunnels to the internet from each provider, and pool all 10 tunnels into one connection to the internet, and those aforementioned devices use that one connection. If I refresh my browser when looking at whatismyip.com, it often will change location from Riga (Romania), to Zurich or another one of the 10 cities I have selected. Therefore that connection is never down because if one tunnel is down trhe connection just goes through a different tunnel. So I am comfortable with that at least (of course it slows down the connection but it’s only down from 1Gig to about a third of that which is not the end of the world)…

Thanks for the reply! I did not know (The Yolink integration uses MQTT under the covers even if you do not have the MQTT integration installed.) That explains part of what is going on. I never had problem before update 11.1 (?)
Duck DNS is essential for me because nearly all of my integrations need Cloud Access. I have no idea how to setup the VPN that you describe, As for the past few months, I have my head wrapped around the YoLink communications problem! But, if you can share the how-to I will set it up.

I do have cloudflare on all my WAN address(s). Since my HA is broke again, I need to configure a new VM for HA anyway. I will try the afore mentioned integration and see if it can replace DuckDNS and NGINX :hand_with_index_finger_and_thumb_crossed:.
Also, feel free to direct message me with any detailed instruction if needed.
OMG, Thank You for your help!!