Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Excessive TIME_WAIT sockets on BI server from Home Assistant #179

Open
exx76 opened this issue Aug 25, 2022 · 0 comments
Open

Excessive TIME_WAIT sockets on BI server from Home Assistant #179

exx76 opened this issue Aug 25, 2022 · 0 comments

Comments

@exx76
Copy link

exx76 commented Aug 25, 2022

If I restart HA and restart BI, I have a total of 8 sockets in TIME_WAIT on my HA server. As soon as I click to a tab to view cameras, HA begins consuming sockets on BI. It appears to not be reusing existing connections. Over a 30 second period of viewing a dashboard with 2 camera feeds on it, a total of 267 sockets were observed in the TIME_WAIT status. Over the following 5 minutes, that number had increased to 1037.

I do not have streaming enabled, and have tried with both h264 and mjpeg. The behavior is the same.

HA Supervisor 2022.08.3
HA Core 2202.8.6
HAOS 8.4
Frontend 20220802.0 - latest
BI Integration latest available version
BI server 5.5.9.6

This issue has persisted for some time, with previous versions of all components. only today did I finally dig into it and see the sockets in TIME_WAIT.

In the attached example, you can see the 2 ESTABLISHED sessions from HA to BI, and the other 1000+ sockets in TIME_WAIT. The end result of this is port exhaustion.

I have attempted to remove and re-add the integration as mentioned by the poster in the issue re: high CPU utilization, to no avail.

netstat example.txt

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant