mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-01-23 23:20:51 +01:00
[Issue]: Jellyfin crash if client "disappears" without completing the close handshake. #6006
Labels
No labels
area:database
awaiting-feedback
backend
blocked
breaking change: web api
bug
build
ci
confirmed
discussion needed
dotnet future
downstream
duplicate
EFjellyfin.db
enhancement
feature
future
github-actions
good first issue
hdr
help wanted
invalid
investigation
librarydb
live-tv
lyrics
media playback
music
needs testing
nuget
performance
platform
pull-request
question
regression
release critical
requires-web
roadmap
security
security
stale
support
syncplay
ui & ux
upstream
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: starred/jellyfin#6006
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @bigrichwood on GitHub (Jun 13, 2024).
Please describe your bug
Jellyfin sometimes crashes and restarts if a client disconnects unexpectedly.
I have seen this a few times in the last few days, all from different clients, and for slightly different reasons. Each time no clients were playing back any media, there were just web pages open to the main page and the dashboard. In each case the first log entry is:
"The remote party closed the WebSocket connection without completing the close handshake."
The last three instances were:
M1 Macbook Air, connected to Jellyfin web interface via Firefox. Laptop went to sleep automatically and Jellyfin crashed
Windows 11 PC, connected to Jellyfin web interface via Firefox. Put desktop to sleep manually and Jellyfin crashed
Windows 11 PC (a different one, 192.168.0.111 in the logs below), connected to Jellyfin web interface via Firefox. VPN client reconnected causing the PC to drop off the network briefly, Jellyfin crashed.
Reproduction Steps
As yet can't reproduce on demand. It doesn't happen everytime a client disconnects or is suspended, but all crashes happen after this occurs.
I never saw this on 10.8.x, and didn't run some of the earlier 10.9.x versions long enough to see it happen.
Jellyfin Version
Master branch
if other:
10.9.6
Environment
Jellyfin logs
FFmpeg logs
Please attach any browser or client logs here
No response
Please attach any screenshots here
No response
Code of Conduct
@jellyfin-bot commented on GitHub (Jun 13, 2024):
Hi, it seems like your issue report has the following item(s) that need to be addressed:
This is an automated message, currently under testing. Please file an issue here if you encounter any problems.
@felix920506 commented on GitHub (Sep 8, 2024):
I cannot reproduce this on my side using the latest weekly unstable build.
I connected to it in Safari and then killed the browser. I repeated it 5 times and Jellyfin didn't crash. All it does is show a warning message in the logs about a client not completing a handshake.
Please enable debug logging to help us better understand what is going on.
https://jellyfin.org/docs/general/administration/troubleshooting#debug-logging
@DaRealHansForSure commented on GitHub (Dec 6, 2024):
I also observed this issue alot, did my own changes to id, made sure connection is not null and also try catched just in case.
There is no really way to reproduce it, just observed it in the logs many times.
WebSocketController.cs
@lagset commented on GitHub (Dec 7, 2024):
This issue appears in my setup as well, albeit in irregular patterns (sometimes days without, sometimes multiple times in a few hours).
Will investigate further. Setup is Synology DS 420+, jellyfin via docker. The client with which this problem appears is a Sony Android TV, however, it's also the by far most client used in my setup.
@cleming commented on GitHub (Dec 29, 2024):
Hello,
I have exactly the same problem (10.10.3 here), docker + traefik as reverse proxy.
@jellyfin-bot commented on GitHub (Apr 29, 2025):
This issue has gone 120 days without an update and will be closed within 21 days if there is no new activity. To prevent this issue from being closed, please confirm the issue has not already been fixed by providing updated examples or logs.
If you have any questions you can use one of several ways to contact us.
@cleming commented on GitHub (Apr 29, 2025):
no more crash here since #13457 patch, thank you !! <3
@felix920506 commented on GitHub (Apr 29, 2025):
Fixed by #13459 according to comments