Plex leaving behind transcode sessions .... >60GB in temp storage

Plex keeps leaving behind the old transcode sessions. I presume these are from the DVR since the rest of my media direct plays on the TV connected to my server, and they are .ts chunks

The temp directory is currently ~60gb with 15 old sessions. The folders all have the same modified date (3am this morning) but the .ts files within the folders are dated from several days ago (from when the recording was scheduled).

Anyone else notice this behavior?
Will Plex clean them up after some period of time, or is there a bug?

They should get tidied up. Save some logs now and then restart the server and see if they get purged after few minutes

If not, please provide logs

https://support.plex.tv/hc/en-us/articles/201643703-Reporting-issues-with-Plex-Media-Server
https://support.plex.tv/hc/en-us/articles/200250417-Plex-Media-Server-Log-Files

Thanks @sa2000

See below for the logs. Seems like they are not getting cleaned up because they are not empty.

Aug 29, 2017 03:36:50.269 [16237] DEBUG - Transcoder: Cleaning old transcode directory: /storage/ORION/media/temp/Transcode/Sessions/plex-transcode-570a30dcd86943a7d8f97c19336105df-0a8f43f8-8bb6-4ea5-b9b8-a4c1f4ad6bf3
Aug 29, 2017 03:36:50.725 [16237] ERROR - Transcoder: Failed to delete session directory (boost::filesystem::remove: Directory not empty: "/storage/ORION/media/temp/Transcode/Sessions/plex-transcode-570a30dcd86943a7d8f97c19336105df-0a8f43f8-8bb6-4ea5-b9b8-a4c1f4ad6bf3")

was this at end of playback or after restart ? need to establish if there is a process that has some files open when the deletes were done. If it was after playback then it may be just timing issue.

could you get a full filetree list with file names, dates, sizes and also logs after restarting the server

The logs above were from after a restart.

Ironically the Sessions were cleared last night. See log entry for the transcode session listed above. I’m not sure what changed between 3am and 9pm… maybe the transcoder cleaned up .the ts files and then directory could be removed.

Anyways, seems like the cleanup is happening.

Aug 29, 2017 21:11:14.852 [29964] DEBUG - Transcoder: Cleaning old transcode directory: /storage/ORION/media/temp/Transcode/Sessions/plex-transcode-570a30dcd86943a7d8f97c19336105df-0a8f43f8-8bb6-4ea5-b9b8-a4c1f4ad6bf3