SOLVED: ffmpeg Permission denied - Printable Version +- Jellyfin Forum (https://forum.jellyfin.org) +-- Forum: Support (https://forum.jellyfin.org/f-support) +--- Forum: Troubleshooting (https://forum.jellyfin.org/f-troubleshooting) +--- Thread: SOLVED: ffmpeg Permission denied (/t-solved-ffmpeg-permission-denied) Pages:
1
2
|
ffmpeg Permission denied - divinecomedian - 2024-09-27 I recently moved my Jellyfin setup from one VM to another. I'm running Jellyfin using Docker, whatever the latest version is at the time of posting this. I'm unable to transcode because I keep getting an ffmpeg error. See the following ffmpeg log entry: Code: {"Protocol":0,"Id":"640eb9fd78a4666d2e4d6358ed769cb4","Path":"/general-media/music/The Charlie Daniels Band/Me and the Boys/10 - Drinkin\u0027 My Baby Goodbye.flac","EncoderPath":null,"EncoderProtocol":null,"Type":0,"Container":"flac","Size":28157412,"Name":"10 - Drinkin\u0027 My Baby Goodbye","IsRemote":false,"ETag":"8435ff89064aabd6c7072c377e2014d7","RunTimeTicks":2209333330,"ReadAtNativeFramerate":false,"IgnoreDts":false,"IgnoreIndex":false,"GenPtsInput":false,"SupportsTranscoding":true,"SupportsDirectStream":true,"SupportsDirectPlay":true,"IsInfiniteStream":false,"RequiresOpening":false,"OpenToken":null,"RequiresClosing":false,"LiveStreamId":null,"BufferMs":null,"RequiresLooping":false,"SupportsProbing":true,"VideoType":null,"IsoType":null,"Video3DFormat":null,"MediaStreams":[{"Codec":"flac","CodecTag":null,"Language":null,"ColorRange":null,"ColorSpace":null,"ColorTransfer":null,"ColorPrimaries":null,"DvVersionMajor":null,"DvVersionMinor":null,"DvProfile":null,"DvLevel":null,"RpuPresentFlag":null,"ElPresentFlag":null,"BlPresentFlag":null,"DvBlSignalCompatibilityId":null,"Comment":null,"TimeBase":"1/44100","CodecTimeBase":null,"Title":null,"VideoRange":0,"VideoRangeType":0,"VideoDoViTitle":null,"AudioSpatialFormat":0,"LocalizedUndefined":null,"LocalizedDefault":"Default","LocalizedForced":null,"LocalizedExternal":"External","LocalizedHearingImpaired":null,"DisplayTitle":"FLAC - Stereo","NalLengthSize":null,"IsInterlaced":false,"IsAVC":false,"ChannelLayout":"stereo","BitRate":1019580,"BitDepth":16,"RefFrames":null,"PacketLength":null,"Channels":2,"SampleRate":44100,"IsDefault":false,"IsForced":false,"IsHearingImpaired":false,"Height":null,"Width":null,"AverageFrameRate":null,"RealFrameRate":null,"Profile":null,"Type":0,"AspectRatio":null,"Index":0,"Score":null,"IsExternal":false,"DeliveryMethod":null,"DeliveryUrl":null,"IsExternalUrl":null,"IsTextSubtitleStream":false,"SupportsExternalStream":false,"Path":null,"PixelFormat":null,"Level":0,"IsAnamorphic":null},{"Codec":"mjpeg","CodecTag":null,"Language":null,"ColorRange":null,"ColorSpace":"bt470bg","ColorTransfer":null,"ColorPrimaries":null,"DvVersionMajor":null,"DvVersionMinor":null,"DvProfile":null,"DvLevel":null,"RpuPresentFlag":null,"ElPresentFlag":null,"BlPresentFlag":null,"DvBlSignalCompatibilityId":null,"Comment":"Cover (front)","TimeBase":"1/90000","CodecTimeBase":null,"Title":null,"VideoRange":0,"VideoRangeType":0,"VideoDoViTitle":null,"AudioSpatialFormat":0,"LocalizedUndefined":null,"LocalizedDefault":null,"LocalizedForced":null,"LocalizedExternal":null,"LocalizedHearingImpaired":null,"DisplayTitle":null,"NalLengthSize":null,"IsInterlaced":false,"IsAVC":false,"ChannelLayout":null,"BitRate":null,"BitDepth":8,"RefFrames":1,"PacketLength":null,"Channels":null,"SampleRate":null,"IsDefault":false,"IsForced":false,"IsHearingImpaired":false,"Height":449,"Width":449,"AverageFrameRate":null,"RealFrameRate":90000,"Profile":"Baseline","Type":3,"AspectRatio":"1:1","Index":1,"Score":null,"IsExternal":false,"DeliveryMethod":null,"DeliveryUrl":null,"IsExternalUrl":null,"IsTextSubtitleStream":false,"SupportsExternalStream":false,"Path":null,"PixelFormat":"yuvj420p","Level":-99,"IsAnamorphic":false}],"MediaAttachments":[],"Formats":[],"Bitrate":1019580,"Timestamp":null,"RequiredHttpHeaders":{},"TranscodingUrl":null,"TranscodingSubProtocol":0,"TranscodingContainer":null,"AnalyzeDurationMs":null,"DefaultAudioStreamIndex":null,"DefaultSubtitleStreamIndex":null} When I access the Docker container's shell, I'm able to run the exact same /usr/lib/jellyfin-ffmpeg/ffmpeg command as above and the process completes with no problem. I imagine I have some kind of file permission issue, but I don't understand why I'm able to manually run the command, while it fails when Jellyfin runs it. Any help is greatly appreciated! RE: ffmpeg Permission denied - TheDreadPirate - 2024-09-27 Can you fully describe your setup? Including the storage configuration? RE: ffmpeg Permission denied - divinecomedian - 2024-09-28 Sure. Here's the Docker compose file I'm using: Code: services: This is running on a Ubuntu 24.04.1 LTS (GNU/Linux 6.8.0-45-generic x86_64) VM. I mounted /mounts/docker and /mounts/media using these /etc/fstab entries: Code: //nas.home/docker /mounts/docker cifs rw,credentials=/home/jacob/.smb,iocharset=utf8,vers=3.0,noperm,file_mode=0777,dir_mode=0777 0 0 Jellyfin appears to have no other problems, just this transcoding issue. Also, not sure if it's relevant, but the transcodes are kicked off by Finamp downloading songs to my phone, which I have set to reduce the file sizes. RE: ffmpeg Permission denied - TheDreadPirate - 2024-09-28 A) You should never have Jellyfin's database located on a SMB/CIFS share. Fix immediately. /config needs to be on a local drive, preferably a SSD. B) Also, is the image name a typo? What is with the "10" tag? Is that supposed to be 10.9.11? C) Can you share the full jellyfin log via pastebin? RE: ffmpeg Permission denied - divinecomedian - 2024-09-28 A) Oh I didn't realize that. What's the reason not to have it on a share? I had it on there before I moved the docker instance to another VM and it had been working fine. B) It's a valid image tag. My JF server version is 10.9.11. See https://hub.docker.com/layers/jellyfin/jellyfin/10/images/sha256-efc2f4ebef76f0e8d3ea49c87b4c61c7d8847e496dc1fd5a91ce6652e33c116f?context=explore C) I'll get you the log when I get back to my PC. RE: ffmpeg Permission denied - TheDreadPirate - 2024-09-28 Databases make a lot of small transactions that SMB isn't designed to handle, plus even on a LAN the latency is a lot higher than if it were on a local disk. RE: ffmpeg Permission denied - divinecomedian - 2024-09-29 I haven't noticed any latency issues, and like I said previously, everything else has been working just fine. Even transcoding movies works. Here's an ffmpeg log of a successful video transcode using the same directories: https://pastebin.com/raw/dy2KWzzY RE: ffmpeg Permission denied - TheDreadPirate - 2024-09-29 Latency, not in Jellyfin serving you a webpage, but latency is transactions with the database. Thousands a second during high load periods. SMB just isn't made for lots of small transactions. Having your database on a SMB share won't prevent it from working. But eventually, as your library grows, it will get bogged down by this setup. RE: ffmpeg Permission denied - divinecomedian - 2024-09-29 I see, well latency doesn't seem to be the problem here, and I can deal with that down the road. Why does transcoding of video files work but not audio files? It seems as if they'd both get the "Permission denied" error. RE: ffmpeg Permission denied - gnattu - 2024-09-29 SMB filesystem mounts may not provide all file manipulation permission/methods depending on both your client and the server settings which is much harder to fix than just install locally because smb ACL is not something you want to spend time to learn for such simple use case. |