MSattler 387 Posted April 28, 2016 Share Posted April 28, 2016 (edited) So I still have issues with rogue ffmpeg processes killing my server sometimes, usually because of one user whose client is having issues. I've written a powershell script which goes through, finds the pid, finds the proper transcoding log, and then extracts the apikey, playsessionid, content path, bit rates, etc. It comes back with something like this: There are 2 ffmpeg processes running. DeviceID is: bbfd99113b9d4fe4 PID is: 2760 API-Key is: 634fe99e4d17428181e86ae31f669f6f PlaySessionID is: f25f4b8151824ca286e54a2661a15c9b VideoBitRate is: 22.433692 Mbps AudioBitRate is: 0.128 Mbps Content being transcoded: \\tower\Bluray\Ride Along\Ride_Along.mkv DeviceID is: fd77ea5b653b95dc9f482b7d5a45e807 PID is: 5228 API-Key is: c4f9546c1ee64830958f4bf6fa246e7c PlaySessionID is: 39e6be3886a2421bb39bbc934a3d8ad0 VideoBitRate is: 4.680001 Mbps AudioBitRate is: 0.32 Mbps Content being transcoded: \\tower\Bluray\Rocky III\Rocky_III.mkv Total Video Bitrate is: 27.113693 Mbps Total Audio Bitrate is: 0.896 Mbps Total Bitrate is: 28.009693 Mbps Now the next step, I would like to query Emby Server via the API to see if a PlaySessionID is still valid, and if not, kill off the local ffmpeg process. Is it as simple as that? Or do I need to grab all of the active sessions, and then find the PlaySessionID for each? Thanks! Edited April 28, 2016 by MSattler 1 Link to comment Share on other sites More sharing options...
Luke 37090 Posted April 28, 2016 Share Posted April 28, 2016 no, there's currently no api for playsession ids, it's primarily for internal use only. best thing to do is report specific examples with detailed descriptions of the user interactions so that we can solve this from happening and then you won't have to do any of this. Link to comment Share on other sites More sharing options...
MSattler 387 Posted April 28, 2016 Author Share Posted April 28, 2016 no, there's currently no api for playsession ids, it's primarily for internal use only. best thing to do is report specific examples with detailed descriptions of the user interactions so that we can solve this from happening and then you won't have to do any of this. It is too difficult right now, partially because you make it so difficult to figure out which ffmpeg processes are rogue. Part of my script's purpose is for me to be able to easily tell which ffmpeg processes are rogue, which transcode log file they related to. This is something that really should be part of the app, show the process id in the playback area, and include it in the transcode log, and the naming of the transcode log. That makes it much simpler in trying to track down which transcode log files I need to upload. Friday night I had 12 rogue ffmpeg processes which brought the server to a halt. I'm not spending hours trying to figure out which log's were part of the issue. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now