I use a VPS server to run my Plex and to reduce the CPU usage I would like to use optimized version to transcode the media in off-peak. The media is stored on the cloud using rclone. The problem is I do not have a lot of local storage in the VPS. So I cant just store the optimied version localy. The transcode is failing after main sted with this
DEBUG - Job running: EAE_ROOT='/tmp/pms-7aa689ef-558b-4b6e-a881-c615a96777fd/EasyAudioEncoder' FFMPEG_EXTERNAL_LIBS='/var/lib/plexmediaserver/Library/Application\ Support/Plex\ Media\ Server/Codecs/99c90e0-3095-linux-x86_64/' XDG_CACHE_HOME='/var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Cache' XDG_DATA_HOME='/usr/lib/plexmediaserver/Resources' X_PLEX_TOKEN='xxxxxxxxxxxxxxxxxxxx' '/usr/lib/plexmediaserver/Plex Transcoder' '-codec:0' 'mpeg4' '-codec:#0x01' 'mp3' '-analyzeduration' '20000000' '-probesize' '20000000' '-i' '/Plex/HomeMovies/! who.avi' '-filter_complex' '[0:0]scale=w=640:h=480[0];[0]format=pix_fmts=yuv420p|nv12[1]' '-filter_complex' '[0:#0x01] aresample=async=1:ocl='\''stereo'\'':osr=44100[2]' '-map' '[1]' '-codec:0' 'libx264' '-crf:0' '18' '-maxrate:0' '2302k' '-bufsize:0' '4604k' '-r:0' '29.969999999999999' '-preset:0' 'slow' '-level:0' '4.0' '-x264opts:0' 'subme=2:me_range=4:rc_lookahead=20:me=hex' '-map' '[2]' '-codec:1' 'aac' '-b:1' '216k' '-f' 'mp4' '-map_metadata' '-1' '-map_chapters' '-1' '-movflags' '+faststart' '/Plex/HomeMovies/Plex Versions/Optimized for Mobile/.inProgress/_ who.mp4.3740' '-y' '-nostats' '-loglevel' 'quiet' '-loglevel_plex' 'error' '-progressurl' 'http://127.0.0.1:32400/video/:/transcode/session/81046dc3-5879-4ee9-9cba-189b37ffbbcc/b747f72c-c555-4909-8e2a-c6d1f2ae1fcc/progress'
ERROR - [Transcoder] [mp4 @ 0xcb25c0] Unable to re-open /Plex/HomeMovies/Plex Versions/Optimized for Mobile/.inProgress/_ who.mp4.3740 output file for the second pass (faststart)
ERROR - [Transcoder] Error writing trailer of /Plex/HomeMovies/Plex Versions/Optimized for Mobile/.inProgress/_ who.mp4.3740: No such file or directory
If I add a local directory as the destination of the optimzed version it works. If I move it to the cloud storage after it has been transcoded and rescan the media dirs it works again (Plex updates the paths). But I think plex does break for some reason when it is mounted on rclone. I do use writes as cashing mode. Anyway if it could work like the sync and then copy it back it would work fine. So I would like to be able to control where the .inProgress folder is placed.
Mod-Edit: added code tags for the log to make it easier to read
Plex does store optimized versions alongside your media. So it should certainly be on a drive with some capacity.
If that library has multiple folders linked to it you can pick where to store the optimized version (when creating it)… options are:
In folders with original items (creating a subfolder Optimized versions within the movie/season folders)
[top level folder path(s) linked to that library]
For regular transcoding, Plex will use a temporary transcoding folder – you can customize where that folder is supposed to be located (some users are e.g. moving it to a RAM drive). Settings > [Server Name] > Transcoder > Transcoder temporary directory
Edit: corrected the initial version; Plex isn’t using the temporary transcoding folder when creating optimized versions!
I agree it should store the version along side the original or where I point it to, and it works IF it is a normal filesystem. But if the files are located on the cloud Plex fails to generate working version as it places a folder in the optimized version folder called .inProgress. This folder use is not very well documented and what it is used for, but it is this folder I would like to move place on a local drive as the transcode pass fails.
Meaning… you have your files on some kind of Google Cloud, One Drive, Apple Cloud Drive…?
In that case… how exactly do you mount/embed that drive in your local file system?
Well… the regular transcode uses your local file system (unless you tell it otherwise).
Seems to be an issue with writing stuff to the cloud drive itself and how you integrate it.
Sorry… not an expert on rclone. But scanning over their documentation… there’s an awful lot of nasty limitations that can bite you in such a setup (e.g. on how it deals with empty folders).
Well I am sure it is a issue in rclone since it does work on local drive, but I would just like the posibility to decide where the .inProgress folder is located when plex does process optimied version.
So like the option if I want the files along side the orginal or in a seperate folder it would be nice if I could set the temp folder location to a general system one like /tmp/plex or alike.
I’m having this issue as well with similar setup (Rclone + Plex on VPS). I’m not sure what is going on with the .inProgress folder on my remote location (Google Drive). Plex cannot read the final output file and the optimized versions therefore doesnt work.
Is it possible to change the temp / inProgress folder location? It would make sense optimization process would use the “Transcoder temporary directory” and then on conversion completion move the output file to final target location.
Everyone please Vote for this Feature Suggestion, perhaps it gets implemented at some point…