-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
Leak of goroutines with WHEP sources #3118
Comments
Hello, i tried replicating the issue but in my case the number of goroutines remained constant, so there must be some specific configuration combination that triggers the leak. This is my configuration: paths:
nonexisting_url:
source: whep://127.0.0.1:8889/nonexisting/whep
nonexisting_host:
source: whep://nonexisting:8889/nonexisting/whep
working:
source: whep://127.0.0.1:8889/stream/whep can you provide a configuration that allows to trigger the leak? also, can you provide a goroutine dump by using the integrated pprof server? you need to set
|
Hello, the initial report was far from enough, apologies! In fact, trying to isolate what's happening, I end up with the following minimal config:
The other side is a mediamtx instance (v1.5.1) on another machine with the following relevant config:
The camera in question is a shitty one in terms of RTSP. It sends RTP/H264 but:
I noticed that in the mediamtx log, I get the following error in loop, which may hint on the issue location:
Attached is a dump of goroutines after a few minutes (basically the time it took to fill this message) If that's not enough, I can try to take an anonymized recording of the video in question. Or find a way to modify to craft one. It looks like it does connect successfully with WHEP, but because the video format is crap, it ends up retrying to connect, and probably misses some cleanup in the process? |
fixed by #3124 |
This issue is being locked automatically because it has been closed for more than 6 months. |
Which version are you using?
Issue seen on v1.6.0 and on master after the merge of #3110 .
Issue not present AFAICS on v1.5.1
Which operating system are you using?
Describe the issue
The configuration contains a mix of WHEP sources (less than 10), with 3 connecting successfully (the remote endpoints are up) and the others not.
The number of goroutines related to pion/webrtc very quickly raise to thousands (reached 11K in less than 24 hours) - see attached goroutines from pprof.
Describe how to replicate the issue
Did you attach the server logs?
goroutines.txt
yes, goroutines
Did you attach a network dump?
no
The text was updated successfully, but these errors were encountered: