Hello,
I have installed this morning the VELUX KLF200 integration. It works fine. after installing I have restarted the core multiple times without issues.
But tonight I had to restart the core again and then, the Cleux integration is not starting.
The error is :
ConnectionAbortedError: SSL handshake is taking longer than 60.0 seconds: aborting the connection
This is, unfortunately, a known issue with the KLF200. It has a limit of something like 3 TCP connections, and after a while with HA, it fills up all the TCP connections and doesn’t let go of any of them. When this happens, if you reboot HA, you get this error on startup. The only resolution is to reboot the KLF200. Many users, including myself, plug the KLF200 into a switch controllable by HA so that they can remotely reboot the KLF200 by turning the switch off-on.
One thing you can do to help minimize this, is to do a software reboot of the KLF200 when you reboot HA. This can be done using an automation. Here is the one I use:
#Try to reboot Velux when HA reboots
- alias: KLF reboot on hass stop event
description: Reboot the KLF200 in order to avoid SSL Handshake issue
trigger:
- platform: homeassistant
event: shutdown
action:
- service: velux.reboot_gateway
FYI, the reboot trick is also mentioned on the manual page
For the last couple of months I’ve been experiencing the ConnectionAbortedError out of the blue, even with the automatic reboot trigger on HA shutdown. I’ll try executing the software reboot of KLF weekly now.