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

[1.x] Janus server stalls at rooms_mutex lock in janus_videoroom.c #3478

Open
ramprakash110109 opened this issue Nov 15, 2024 · 6 comments
Open
Labels
multistream Related to Janus 1.x needinfo

Comments

@ramprakash110109
Copy link

What version of Janus is this happening on?
v1.2.1

Have you tested a more recent version of Janus too?
No, since it was a rare issue and unable to reproduce again

Was this working before?
This is the second time I am facing this issue in past 6 months

Is there a gdb or libasan trace of the issue?
https://pastebin.com/eVLkvU3H

Additional context
Sessions were running smoothly for more than 3 months.
But suddenly, threads seems to get locked and no http requests or rmq requests were processed in mediaserver.
When I debugged, I came to know that rooms_mutex lock was not unlocked in one of the previous request. But I was unable to find the exact request which caused this issue.

I have pasted the debug_lock output where I hit new http request after the mediaserver gets locked due to some previous request.

I suspect one of the stop_rtp_forward request could have caused this. But I am not sure.

Could you please guide on this?

@ramprakash110109 ramprakash110109 added the multistream Related to Janus 1.x label Nov 15, 2024
@lminiero
Copy link
Member

Please test master, there have been a ton of fixes recently on potential deadlocks.

@ramprakash110109
Copy link
Author

videoroom.c code is almost same inmy version too. anyways, we will try to check latest master as well. Thanks

@lminiero
Copy link
Member

@ramprakash110109 any update?

@ramprakash110109
Copy link
Author

ramprakash110109 commented Dec 12, 2024 via email

@Dev2Trailblazer
Copy link

We have been running janus-gateway v1.3.0 for ~1 month, and we occasionally get similar behavior to this one. Randomly, one of our instances stops responding to all HTTP requests, for example:

  • POST /janus/{sessionID} (attach janus.plugin.videoroom)
  • POST /janus/{sessionID} (keepalive)

Instances keep failing from time to time, so it's possible that we can reproduce the issue. I'm not sure this is the same issue as this ticket. Do you have any suggestions for us on debugging it or providing more data?

Thank you!

@atoppi
Copy link
Member

atoppi commented Jan 16, 2025

The usual steps for similar issues:

  • try to reproduce with AddressSanitizer
  • enable lock debugging
    Expect a downgrade in performance and an increase in disk usage if you are saving the logs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
multistream Related to Janus 1.x needinfo
Projects
None yet
Development

No branches or pull requests

4 participants