Jellyfin Forum
SOLVED: Hardware Transcoding - 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: Hardware Transcoding (/t-solved-hardware-transcoding)

Pages: 1 2 3


Hardware Transcoding - PapaTrotsky - 2023-11-13

Edit/Solution: I solved it!
Essentially what I had to do was modify my jellyfin container by: adding this line to my extra parameters under Advanced View
Extra Parameters: -e NVIDIA_DRIVER_CAPABILITIES=all  -e NVIDIA_VISIBLE_DEVICES=all  --gpus all
That's the exact line I used, I copy and pasted exactly that, obviously without the Extra Parameters part.
Than I created 2 variables in the container editor.

Variable 1:
Name: NVIDIA_VISIBLE_DEVICES
Key: NVIDIA_VISIBLE_DEVICES
value: all

Variable 2:
Name: NVIDIA_DRIVER_CAPABILITIES
Key: NVIDIA_DRIVER_CAPABILITIES
Value: all

Aside from this you need to make sure NVIDIA drivers and NVIDIA container toolkit is installed. On Unraid, you can install the "Nvidia Driver" app/plugin from the built-in apps installer, the author at time of writing is 'ich777'.
The container toolkit just works, I assume it comes with the drivers.
I also installed "GPU Statistics" I don't think it's necessary but it's nice to see how the GPU is performing.
After that I just setup the hardware transcoding on jellyfin and was good to go.

Original post:

Hello, I recently got into Jellyfin and after a few issues I have it working 90% of the way. I am able to stream my shows if I turn off hardware acceleration but when I set it to NVENC it stops loading and gives a Playback Error stating "This client is compatible with the media and the server isn't able to send a compatible media format."

I am running a jellyfin docker container off of my home server running unRaid. The server has a Ryzen 7 1700 and Geforce GTX 1050ti. I've tried following the jellyfin guide, the linuxserver.io guide, and the NVIDIA guide. The guides are all confusingly written, have steps out of order and all over the place and I've been working on this for 5 hours now and missed 2 classes so I'm finally asking for help. Incase it's relevant the show I'm testing with is a 'definitely legally acquired' copy of the first 13 seasons of Top Gear which aren't available on any streaming platform in my country. Jellyfin says the video is in 360p MPEG4 SDR which seems oddly low quality. The media files are MKV format and ~350 MB for an hour long episode.

This is what my log spits out every time I try to run the show with NVENC on. I added some information of my settings on Jellyfin after the log.
Code:
[17:12:21] [INF] [37] Jellyfin.Api.Helpers.MediaInfoHelper: User policy for michael. EnablePlaybackRemuxing: True EnableVideoPlaybackTranscoding: True EnableAudioPlaybackTranscoding: True
[17:12:21] [INF] [37] Jellyfin.Api.Helpers.MediaInfoHelper: StreamBuilder.BuildVideoItem( Profile=Anonymous Profile, Path=/data/tvshows/Top Gear (UK)/Season 1/S01E01.mkv, AudioStreamIndex=null, SubtitleStreamIndex=null ) => ( PlayMethod=Transcode, TranscodeReason=VideoCodecNotSupported, AudioCodecNotSupported ) media:/videos/3a2116c7-99fe-effa-0362-0923d3050881/master.m3u8?MediaSourceId=3a2116c799feeffa03620923d3050881&VideoCodec=h264&AudioCodec=mp3&AudioStreamIndex=1&VideoBitrate=139872000&AudioBitrate=128000&AudioSampleRate=32000&MaxFramerate=25&api_key=<token>&TranscodingMaxAudioChannels=8&RequireAvc=false&Tag=3b846e40d6c9131a699b6e24f6575312&SegmentContainer=ts&MinSegments=1&BreakOnNonKeyFrames=True&mpeg4-level=-99&mpeg4-videobitdepth=8&mpeg4-audiochannels=2&TranscodeReasons=VideoCodecNotSupported,%20AudioCodecNotSupported
[17:12:21] [INF] [15] Jellyfin.Api.Controllers.DynamicHlsController: Current HLS implementation doesn't support non-keyframe breaks but one is requested, ignoring that request
[17:12:21] [INF] [15] Jellyfin.Api.Helpers.TranscodingJobHelper: /usr/lib/jellyfin-ffmpeg/ffmpeg -analyzeduration 200M -init_hw_device cuda=cu:0 -filter_hw_device cu -autorotate 0 -i file:"/data/tvshows/Top Gear (UK)/Season 1/S01E01.mkv" -map_metadata -1 -map_chapters -1 -threads 8 -map 0:0 -map 0:1 -map -0:s -codec:v:0 h264_nvenc -preset p1 -b:v 4214080 -maxrate 4214080 -bufsize 8428160 -g:v:0 75 -keyint_min:v:0 75 -vf "setparams=color_primaries=bt709:color_trc=bt709:colorspace=bt709,scale=trunc(min(max(iw\,ih*a)\,min(512\,328*a))/2)*2:trunc(min(max(iw/a\,ih)\,min(512/a\,328))/2)*2,format=yuv420p" -codec:a:0 copy -copyts -avoid_negative_ts disabled -max_muxing_queue_size 2048 -f hls -max_delay 5000000 -hls_time 3 -hls_segment_type mpegts -start_number 0 -hls_segment_filename "/config/data/transcodes/b340767f033df36935479574824ba104%d.ts" -hls_playlist_type vod -hls_list_size 0 -y "/config/data/transcodes/b340767f033df36935479574824ba104.m3u8"
[17:12:21] [ERR] [36] Jellyfin.Api.Helpers.TranscodingJobHelper: FFmpeg exited with code 1
[17:12:21] [ERR] [33] Jellyfin.Server.Middleware.ExceptionMiddleware: Error processing request. URL GET /videos/3a2116c7-99fe-effa-0362-0923d3050881/hls1/main/0.ts.
MediaBrowser.Common.FfmpegException: FFmpeg exited with code 1
  at Jellyfin.Api.Helpers.TranscodingJobHelper.StartFfMpeg(StreamState state, String outputPath, String commandLineArguments, HttpRequest request, TranscodingJobType transcodingJobType, CancellationTokenSource cancellationTokenSource, String workingDirectory)
  at Jellyfin.Api.Controllers.DynamicHlsController.GetDynamicSegment(StreamingRequestDto streamingRequest, Int32 segmentId)
  at Jellyfin.Api.Controllers.DynamicHlsController.GetHlsVideoSegment(Guid itemId, String playlistId, Int32 segmentId, String container, Int64 runtimeTicks, Int64 actualSegmentLengthTicks, Nullable`1 static, String params, String tag, String deviceProfileId, String playSessionId, String segmentContainer, Nullable`1 segmentLength, Nullable`1 minSegments, String mediaSourceId, String deviceId, String audioCodec, Nullable`1 enableAutoStreamCopy, Nullable`1 allowVideoStreamCopy, Nullable`1 allowAudioStreamCopy, Nullable`1 breakOnNonKeyFrames, Nullable`1 audioSampleRate, Nullable`1 maxAudioBitDepth, Nullable`1 audioBitRate, Nullable`1 audioChannels, Nullable`1 maxAudioChannels, String profile, String level, Nullable`1 framerate, Nullable`1 maxFramerate, Nullable`1 copyTimestamps, Nullable`1 startTimeTicks, Nullable`1 width, Nullable`1 height, Nullable`1 maxWidth, Nullable`1 maxHeight, Nullable`1 videoBitRate, Nullable`1 subtitleStreamIndex, Nullable`1 subtitleMethod, Nullable`1 maxRefFrames, Nullable`1 maxVideoBitDepth, Nullable`1 requireAvc, Nullable`1 deInterlace, Nullable`1 requireNonAnamorphic, Nullable`1 transcodingMaxAudioChannels, Nullable`1 cpuCoreLimit, String liveStreamId, Nullable`1 enableMpegtsM2TsMode, String videoCodec, String subtitleCodec, String transcodeReasons, Nullable`1 audioStreamIndex, Nullable`1 videoStreamIndex, Nullable`1 context, Dictionary`2 streamOptions)
  at lambda_method956(Closure , Object )
  at Microsoft.AspNetCore.Mvc.Infrastructure.ActionMethodExecutor.TaskOfActionResultExecutor.Execute(IActionResultTypeMapper mapper, ObjectMethodExecutor executor, Object controller, Object[] arguments)
  at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.<InvokeActionMethodAsync>g__Awaited|12_0(ControllerActionInvoker invoker, ValueTask`1 actionResultValueTask)
  at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.<InvokeNextActionFilterAsync>g__Awaited|10_0(ControllerActionInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)
  at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.Rethrow(ActionExecutedContextSealed context)
  at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.Next(State& next, Scope& scope, Object& state, Boolean& isCompleted)
  at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.<InvokeInnerFilterAsync>g__Awaited|13_0(ControllerActionInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)
  at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<InvokeNextResourceFilter>g__Awaited|25_0(ResourceInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)
  at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.Rethrow(ResourceExecutedContextSealed context)
  at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.Next(State& next, Scope& scope, Object& state, Boolean& isCompleted)
  at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<InvokeFilterPipelineAsync>g__Awaited|20_0(ResourceInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)
  at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<InvokeAsync>g__Awaited|17_0(ResourceInvoker invoker, Task task, IDisposable scope)
  at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<InvokeAsync>g__Awaited|17_0(ResourceInvoker invoker, Task task, IDisposable scope)
  at Microsoft.AspNetCore.Routing.EndpointMiddleware.<Invoke>g__AwaitRequestTask|6_0(Endpoint endpoint, Task requestTask, ILogger logger)
  at Jellyfin.Server.Middleware.ServerStartupMessageMiddleware.Invoke(HttpContext httpContext, IServerApplicationHost serverApplicationHost, ILocalizationManager localizationManager)
  at Jellyfin.Server.Middleware.WebSocketHandlerMiddleware.Invoke(HttpContext httpContext, IWebSocketManager webSocketManager)
  at Jellyfin.Server.Middleware.IpBasedAccessValidationMiddleware.Invoke(HttpContext httpContext, INetworkManager networkManager)
  at Jellyfin.Server.Middleware.LanFilteringMiddleware.Invoke(HttpContext httpContext, INetworkManager networkManager, IServerConfigurationManager serverConfigurationManager)
  at Microsoft.AspNetCore.Authorization.Policy.AuthorizationMiddlewareResultHandler.HandleAsync(RequestDelegate next, HttpContext context, AuthorizationPolicy policy, PolicyAuthorizationResult authorizeResult)
  at Microsoft.AspNetCore.Authorization.AuthorizationMiddleware.Invoke(HttpContext context)
  at Jellyfin.Server.Middleware.QueryStringDecodingMiddleware.Invoke(HttpContext httpContext)
  at Swashbuckle.AspNetCore.ReDoc.ReDocMiddleware.Invoke(HttpContext httpContext)
  at Swashbuckle.AspNetCore.SwaggerUI.SwaggerUIMiddleware.Invoke(HttpContext httpContext)
  at Swashbuckle.AspNetCore.Swagger.SwaggerMiddleware.Invoke(HttpContext httpContext, ISwaggerProvider swaggerProvider)
  at Microsoft.AspNetCore.Authentication.AuthenticationMiddleware.Invoke(HttpContext context)
  at Jellyfin.Server.Middleware.RobotsRedirectionMiddleware.Invoke(HttpContext httpContext)
  at Jellyfin.Server.Middleware.LegacyEmbyRouteRewriteMiddleware.Invoke(HttpContext httpContext)
  at Microsoft.AspNetCore.ResponseCompression.ResponseCompressionMiddleware.InvokeCore(HttpContext context)
  at Jellyfin.Server.Middleware.ResponseTimeMiddleware.Invoke(HttpContext context, IServerConfigurationManager serverConfigurationManager)
  at Jellyfin.Server.Middleware.ExceptionMiddleware.Invoke(HttpContext context)
[17:12:21] [INF] [36] Jellyfin.Api.Helpers.MediaInfoHelper: User policy for michael. EnablePlaybackRemuxing: True EnableVideoPlaybackTranscoding: True EnableAudioPlaybackTranscoding: True
[17:12:21] [INF] [36] Jellyfin.Api.Helpers.MediaInfoHelper: StreamBuilder.BuildVideoItem( Profile=Anonymous Profile, Path=/data/tvshows/Top Gear (UK)/Season 1/S01E01.mkv, AudioStreamIndex=1, SubtitleStreamIndex=null ) => ( PlayMethod=Transcode, TranscodeReason=VideoCodecNotSupported, AudioCodecNotSupported ) media:/videos/3a2116c7-99fe-effa-0362-0923d3050881/master.m3u8?MediaSourceId=3a2116c799feeffa03620923d3050881&VideoCodec=h264&AudioCodec=mp3&AudioStreamIndex=1&VideoBitrate=139872000&AudioBitrate=128000&AudioSampleRate=32000&MaxFramerate=25&api_key=<token>&TranscodingMaxAudioChannels=8&RequireAvc=false&Tag=3b846e40d6c9131a699b6e24f6575312&SegmentContainer=ts&MinSegments=1&BreakOnNonKeyFrames=True&mpeg4-level=-99&mpeg4-videobitdepth=8&mpeg4-audiochannels=2&TranscodeReasons=VideoCodecNotSupported,%20AudioCodecNotSupported
[17:12:21] [INF] [36] Jellyfin.Api.Helpers.TranscodingJobHelper: Deleting partial stream file(s) /config/data/transcodes/b340767f033df36935479574824ba104.m3u8
[17:12:21] [INF] [35] Jellyfin.Api.Controllers.DynamicHlsController: Current HLS implementation doesn't support non-keyframe breaks but one is requested, ignoring that request
[17:12:21] [INF] [35] Jellyfin.Api.Helpers.TranscodingJobHelper: /usr/lib/jellyfin-ffmpeg/ffmpeg -analyzeduration 200M -init_hw_device cuda=cu:0 -filter_hw_device cu -autorotate 0 -i file:"/data/tvshows/Top Gear (UK)/Season 1/S01E01.mkv" -map_metadata -1 -map_chapters -1 -threads 8 -map 0:0 -map 0:1 -map -0:s -codec:v:0 h264_nvenc -preset p1 -b:v 4214080 -maxrate 4214080 -bufsize 8428160 -g:v:0 75 -keyint_min:v:0 75 -vf "setparams=color_primaries=bt709:color_trc=bt709:colorspace=bt709,scale=trunc(min(max(iw\,ih*a)\,min(512\,328*a))/2)*2:trunc(min(max(iw/a\,ih)\,min(512/a\,328))/2)*2,format=yuv420p" -codec:a:0 copy -copyts -avoid_negative_ts disabled -max_muxing_queue_size 2048 -f hls -max_delay 5000000 -hls_time 3 -hls_segment_type mpegts -start_number 0 -hls_segment_filename "/config/data/transcodes/36630a27dc5517188adaa043915cde88%d.ts" -hls_playlist_type vod -hls_list_size 0 -y "/config/data/transcodes/36630a27dc5517188adaa043915cde88.m3u8"
[17:12:21] [ERR] [35] Jellyfin.Api.Helpers.TranscodingJobHelper: FFmpeg exited with code 1
[17:12:21] [ERR] [35] Jellyfin.Server.Middleware.ExceptionMiddleware: Error processing request. URL GET /videos/3a2116c7-99fe-effa-0362-0923d3050881/hls1/main/0.ts.
MediaBrowser.Common.FfmpegException: FFmpeg exited with code 1
  at Jellyfin.Api.Helpers.TranscodingJobHelper.StartFfMpeg(StreamState state, String outputPath, String commandLineArguments, HttpRequest request, TranscodingJobType transcodingJobType, CancellationTokenSource cancellationTokenSource, String workingDirectory)
  at Jellyfin.Api.Controllers.DynamicHlsController.GetDynamicSegment(StreamingRequestDto streamingRequest, Int32 segmentId)
  at Jellyfin.Api.Controllers.DynamicHlsController.GetHlsVideoSegment(Guid itemId, String playlistId, Int32 segmentId, String container, Int64 runtimeTicks, Int64 actualSegmentLengthTicks, Nullable`1 static, String params, String tag, String deviceProfileId, String playSessionId, String segmentContainer, Nullable`1 segmentLength, Nullable`1 minSegments, String mediaSourceId, String deviceId, String audioCodec, Nullable`1 enableAutoStreamCopy, Nullable`1 allowVideoStreamCopy, Nullable`1 allowAudioStreamCopy, Nullable`1 breakOnNonKeyFrames, Nullable`1 audioSampleRate, Nullable`1 maxAudioBitDepth, Nullable`1 audioBitRate, Nullable`1 audioChannels, Nullable`1 maxAudioChannels, String profile, String level, Nullable`1 framerate, Nullable`1 maxFramerate, Nullable`1 copyTimestamps, Nullable`1 startTimeTicks, Nullable`1 width, Nullable`1 height, Nullable`1 maxWidth, Nullable`1 maxHeight, Nullable`1 videoBitRate, Nullable`1 subtitleStreamIndex, Nullable`1 subtitleMethod, Nullable`1 maxRefFrames, Nullable`1 maxVideoBitDepth, Nullable`1 requireAvc, Nullable`1 deInterlace, Nullable`1 requireNonAnamorphic, Nullable`1 transcodingMaxAudioChannels, Nullable`1 cpuCoreLimit, String liveStreamId, Nullable`1 enableMpegtsM2TsMode, String videoCodec, String subtitleCodec, String transcodeReasons, Nullable`1 audioStreamIndex, Nullable`1 videoStreamIndex, Nullable`1 context, Dictionary`2 streamOptions)
  at lambda_method956(Closure , Object )
  at Microsoft.AspNetCore.Mvc.Infrastructure.ActionMethodExecutor.TaskOfActionResultExecutor.Execute(IActionResultTypeMapper mapper, ObjectMethodExecutor executor, Object controller, Object[] arguments)
  at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.<InvokeActionMethodAsync>g__Awaited|12_0(ControllerActionInvoker invoker, ValueTask`1 actionResultValueTask)
  at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.<InvokeNextActionFilterAsync>g__Awaited|10_0(ControllerActionInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)
  at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.Rethrow(ActionExecutedContextSealed context)
  at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.Next(State& next, Scope& scope, Object& state, Boolean& isCompleted)
  at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.<InvokeInnerFilterAsync>g__Awaited|13_0(ControllerActionInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)
  at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<InvokeNextResourceFilter>g__Awaited|25_0(ResourceInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)
  at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.Rethrow(ResourceExecutedContextSealed context)
  at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.Next(State& next, Scope& scope, Object& state, Boolean& isCompleted)
  at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<InvokeFilterPipelineAsync>g__Awaited|20_0(ResourceInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)
  at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<InvokeAsync>g__Awaited|17_0(ResourceInvoker invoker, Task task, IDisposable scope)
  at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<InvokeAsync>g__Awaited|17_0(ResourceInvoker invoker, Task task, IDisposable scope)
  at Microsoft.AspNetCore.Routing.EndpointMiddleware.<Invoke>g__AwaitRequestTask|6_0(Endpoint endpoint, Task requestTask, ILogger logger)
  at Jellyfin.Server.Middleware.ServerStartupMessageMiddleware.Invoke(HttpContext httpContext, IServerApplicationHost serverApplicationHost, ILocalizationManager localizationManager)
  at Jellyfin.Server.Middleware.WebSocketHandlerMiddleware.Invoke(HttpContext httpContext, IWebSocketManager webSocketManager)
  at Jellyfin.Server.Middleware.IpBasedAccessValidationMiddleware.Invoke(HttpContext httpContext, INetworkManager networkManager)
  at Jellyfin.Server.Middleware.LanFilteringMiddleware.Invoke(HttpContext httpContext, INetworkManager networkManager, IServerConfigurationManager serverConfigurationManager)
  at Microsoft.AspNetCore.Authorization.Policy.AuthorizationMiddlewareResultHandler.HandleAsync(RequestDelegate next, HttpContext context, AuthorizationPolicy policy, PolicyAuthorizationResult authorizeResult)
  at Microsoft.AspNetCore.Authorization.AuthorizationMiddleware.Invoke(HttpContext context)
  at Jellyfin.Server.Middleware.QueryStringDecodingMiddleware.Invoke(HttpContext httpContext)
  at Swashbuckle.AspNetCore.ReDoc.ReDocMiddleware.Invoke(HttpContext httpContext)
  at Swashbuckle.AspNetCore.SwaggerUI.SwaggerUIMiddleware.Invoke(HttpContext httpContext)
  at Swashbuckle.AspNetCore.Swagger.SwaggerMiddleware.Invoke(HttpContext httpContext, ISwaggerProvider swaggerProvider)
  at Microsoft.AspNetCore.Authentication.AuthenticationMiddleware.Invoke(HttpContext context)
  at Jellyfin.Server.Middleware.RobotsRedirectionMiddleware.Invoke(HttpContext httpContext)
  at Jellyfin.Server.Middleware.LegacyEmbyRouteRewriteMiddleware.Invoke(HttpContext httpContext)
  at Microsoft.AspNetCore.ResponseCompression.ResponseCompressionMiddleware.InvokeCore(HttpContext context)
  at Jellyfin.Server.Middleware.ResponseTimeMiddleware.Invoke(HttpContext context, IServerConfigurationManager serverConfigurationManager)
  at Jellyfin.Server.Middleware.ExceptionMiddleware.Invoke(HttpContext context)
[17:12:22] [INF] [33] Jellyfin.Api.Helpers.MediaInfoHelper: User policy for michael. EnablePlaybackRemuxing: True EnableVideoPlaybackTranscoding: True EnableAudioPlaybackTranscoding: True
[17:12:22] [INF] [33] Jellyfin.Api.Helpers.MediaInfoHelper: StreamBuilder.BuildVideoItem( Profile=Anonymous Profile, Path=/data/tvshows/Top Gear (UK)/Season 1/S01E01.mkv, AudioStreamIndex=1, SubtitleStreamIndex=null ) => ( PlayMethod=Transcode, TranscodeReason=VideoCodecNotSupported, AudioCodecNotSupported ) media:/videos/3a2116c7-99fe-effa-0362-0923d3050881/master.m3u8?MediaSourceId=3a2116c799feeffa03620923d3050881&VideoCodec=h264&AudioCodec=mp3&AudioStreamIndex=1&VideoBitrate=139872000&AudioBitrate=128000&AudioSampleRate=32000&MaxFramerate=25&api_key=<token>&TranscodingMaxAudioChannels=8&RequireAvc=false&Tag=3b846e40d6c9131a699b6e24f6575312&SegmentContainer=ts&MinSegments=1&BreakOnNonKeyFrames=True&mpeg4-level=-99&mpeg4-videobitdepth=8&mpeg4-audiochannels=2&TranscodeReasons=VideoCodecNotSupported,%20AudioCodecNotSupported
[17:12:22] [INF] [33] Jellyfin.Api.Helpers.TranscodingJobHelper: Deleting partial stream file(s) /config/data/transcodes/36630a27dc5517188adaa043915cde88.m3u8
[17:12:22] [INF] [38] Jellyfin.Api.Controllers.DynamicHlsController: Current HLS implementation doesn't support non-keyframe breaks but one is requested, ignoring that request
[17:12:22] [INF] [38] Jellyfin.Api.Helpers.TranscodingJobHelper: /usr/lib/jellyfin-ffmpeg/ffmpeg -analyzeduration 200M -init_hw_device cuda=cu:0 -filter_hw_device cu -autorotate 0 -i file:"/data/tvshows/Top Gear (UK)/Season 1/S01E01.mkv" -map_metadata -1 -map_chapters -1 -threads 8 -map 0:0 -map 0:1 -map -0:s -codec:v:0 h264_nvenc -preset p1 -b:v 4214080 -maxrate 4214080 -bufsize 8428160 -g:v:0 75 -keyint_min:v:0 75 -vf "setparams=color_primaries=bt709:color_trc=bt709:colorspace=bt709,scale=trunc(min(max(iw\,ih*a)\,min(512\,328*a))/2)*2:trunc(min(max(iw/a\,ih)\,min(512/a\,328))/2)*2,format=yuv420p" -codec:a:0 libmp3lame -ac 2 -ab 128000 -ar 32000 -copyts -avoid_negative_ts disabled -max_muxing_queue_size 2048 -f hls -max_delay 5000000 -hls_time 3 -hls_segment_type mpegts -start_number 0 -hls_segment_filename "/config/data/transcodes/4c3be470a6a96e9a6f41fb83a2740c63%d.ts" -hls_playlist_type vod -hls_list_size 0 -y "/config/data/transcodes/4c3be470a6a96e9a6f41fb83a2740c63.m3u8"
[17:12:22] [ERR] [38] Jellyfin.Api.Helpers.TranscodingJobHelper: FFmpeg exited with code 1
[17:12:22] [ERR] [38] Jellyfin.Server.Middleware.ExceptionMiddleware: Error processing request. URL GET /videos/3a2116c7-99fe-effa-0362-0923d3050881/hls1/main/0.ts.
MediaBrowser.Common.FfmpegException: FFmpeg exited with code 1
  at Jellyfin.Api.Helpers.TranscodingJobHelper.StartFfMpeg(StreamState state, String outputPath, String commandLineArguments, HttpRequest request, TranscodingJobType transcodingJobType, CancellationTokenSource cancellationTokenSource, String workingDirectory)
  at Jellyfin.Api.Controllers.DynamicHlsController.GetDynamicSegment(StreamingRequestDto streamingRequest, Int32 segmentId)
  at Jellyfin.Api.Controllers.DynamicHlsController.GetHlsVideoSegment(Guid itemId, String playlistId, Int32 segmentId, String container, Int64 runtimeTicks, Int64 actualSegmentLengthTicks, Nullable`1 static, String params, String tag, String deviceProfileId, String playSessionId, String segmentContainer, Nullable`1 segmentLength, Nullable`1 minSegments, String mediaSourceId, String deviceId, String audioCodec, Nullable`1 enableAutoStreamCopy, Nullable`1 allowVideoStreamCopy, Nullable`1 allowAudioStreamCopy, Nullable`1 breakOnNonKeyFrames, Nullable`1 audioSampleRate, Nullable`1 maxAudioBitDepth, Nullable`1 audioBitRate, Nullable`1 audioChannels, Nullable`1 maxAudioChannels, String profile, String level, Nullable`1 framerate, Nullable`1 maxFramerate, Nullable`1 copyTimestamps, Nullable`1 startTimeTicks, Nullable`1 width, Nullable`1 height, Nullable`1 maxWidth, Nullable`1 maxHeight, Nullable`1 videoBitRate, Nullable`1 subtitleStreamIndex, Nullable`1 subtitleMethod, Nullable`1 maxRefFrames, Nullable`1 maxVideoBitDepth, Nullable`1 requireAvc, Nullable`1 deInterlace, Nullable`1 requireNonAnamorphic, Nullable`1 transcodingMaxAudioChannels, Nullable`1 cpuCoreLimit, String liveStreamId, Nullable`1 enableMpegtsM2TsMode, String videoCodec, String subtitleCodec, String transcodeReasons, Nullable`1 audioStreamIndex, Nullable`1 videoStreamIndex, Nullable`1 context, Dictionary`2 streamOptions)
  at lambda_method956(Closure , Object )
  at Microsoft.AspNetCore.Mvc.Infrastructure.ActionMethodExecutor.TaskOfActionResultExecutor.Execute(IActionResultTypeMapper mapper, ObjectMethodExecutor executor, Object controller, Object[] arguments)
  at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.<InvokeActionMethodAsync>g__Awaited|12_0(ControllerActionInvoker invoker, ValueTask`1 actionResultValueTask)
  at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.<InvokeNextActionFilterAsync>g__Awaited|10_0(ControllerActionInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)
  at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.Rethrow(ActionExecutedContextSealed context)
  at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.Next(State& next, Scope& scope, Object& state, Boolean& isCompleted)
  at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.<InvokeInnerFilterAsync>g__Awaited|13_0(ControllerActionInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)
  at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<InvokeNextResourceFilter>g__Awaited|25_0(ResourceInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)
  at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.Rethrow(ResourceExecutedContextSealed context)
  at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.Next(State& next, Scope& scope, Object& state, Boolean& isCompleted)
  at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<InvokeFilterPipelineAsync>g__Awaited|20_0(ResourceInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)
  at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<InvokeAsync>g__Awaited|17_0(ResourceInvoker invoker, Task task, IDisposable scope)
  at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<InvokeAsync>g__Awaited|17_0(ResourceInvoker invoker, Task task, IDisposable scope)
  at Microsoft.AspNetCore.Routing.EndpointMiddleware.<Invoke>g__AwaitRequestTask|6_0(Endpoint endpoint, Task requestTask, ILogger logger)
  at Jellyfin.Server.Middleware.ServerStartupMessageMiddleware.Invoke(HttpContext httpContext, IServerApplicationHost serverApplicationHost, ILocalizationManager localizationManager)
  at Jellyfin.Server.Middleware.WebSocketHandlerMiddleware.Invoke(HttpContext httpContext, IWebSocketManager webSocketManager)
  at Jellyfin.Server.Middleware.IpBasedAccessValidationMiddleware.Invoke(HttpContext httpContext, INetworkManager networkManager)
  at Jellyfin.Server.Middleware.LanFilteringMiddleware.Invoke(HttpContext httpContext, INetworkManager networkManager, IServerConfigurationManager serverConfigurationManager)
  at Microsoft.AspNetCore.Authorization.Policy.AuthorizationMiddlewareResultHandler.HandleAsync(RequestDelegate next, HttpContext context, AuthorizationPolicy policy, PolicyAuthorizationResult authorizeResult)
  at Microsoft.AspNetCore.Authorization.AuthorizationMiddleware.Invoke(HttpContext context)
  at Jellyfin.Server.Middleware.QueryStringDecodingMiddleware.Invoke(HttpContext httpContext)
  at Swashbuckle.AspNetCore.ReDoc.ReDocMiddleware.Invoke(HttpContext httpContext)
  at Swashbuckle.AspNetCore.SwaggerUI.SwaggerUIMiddleware.Invoke(HttpContext httpContext)
  at Swashbuckle.AspNetCore.Swagger.SwaggerMiddleware.Invoke(HttpContext httpContext, ISwaggerProvider swaggerProvider)
  at Microsoft.AspNetCore.Authentication.AuthenticationMiddleware.Invoke(HttpContext context)
  at Jellyfin.Server.Middleware.RobotsRedirectionMiddleware.Invoke(HttpContext httpContext)
  at Jellyfin.Server.Middleware.LegacyEmbyRouteRewriteMiddleware.Invoke(HttpContext httpContext)
  at Microsoft.AspNetCore.ResponseCompression.ResponseCompressionMiddleware.InvokeCore(HttpContext context)
  at Jellyfin.Server.Middleware.ResponseTimeMiddleware.Invoke(HttpContext context, IServerConfigurationManager serverConfigurationManager)
  at Jellyfin.Server.Middleware.ExceptionMiddleware.Invoke(HttpContext context)
[17:12:22] [INF] [38] Jellyfin.Api.Helpers.TranscodingJobHelper: Deleting partial stream file(s) /config/data/transcodes/4c3be470a6a96e9a6f41fb83a2740c63.m3u8
[17:12:23] [INF] [40] Emby.Server.Implementations.Session.SessionManager: Playback stopped reported by app Jellyfin Web 10.8.12 playing S01E01. Stopped at 0 ms
[17:12:23] [WRN] [40] Jellyfin.Server.Middleware.ResponseTimeMiddleware: Slow HTTP Response from http://192.168.0.100:8096/Sessions/Playing/Stopped to 192.168.0.197 in 0:00:01.5324906 with Status Code 204

Enable hardware decoding for:
HEVC, VC1, HEVC 10bit, VP9 10bit 
Enable enhanced NVDEC decoder (on)
Hardware encoding options:
Enable hardware encoding (on)
Allow encoding in HEVC format (on)
Enable Tone mapping (on with BT.2390 Algorithim)
Tone Mapping Mode: Auto
Tone Mapping Range: Auto
Tone Mapping Deset: 0
Tone Mapping Peak: 100
Tone Mapping Param: (blank)
Transcoding Thread Count: 8
FFmpeg Path: /usr/lib/jellyfin-ffmpeg/ffmpeg (I think this may be what's causing my issue but I'm not sure and I'm scared to break it worse)
Transcode Path: /config/data/transcodes
Fallback Font Folder Path: (blank)
Enable Fallback Fonts: (off)
Audio Boost when downmixing: 2
Max muxing queue size: 2048
Encoding Preset: Auto
H.265 Encoding CRF: 28
H.264 Encoding CRF: 23
Deinterlacing Method: YADIF
Double the framerate when deinterlacing: (off)
Allow subtitle extraction on the fly: (on)
Throttle Trancodes: (off)


RE: Hardware Transcoding - TheDreadPirate - 2023-11-14

We don't have an official guide for setting up GPU acceleration with unraid. But guides exist on the internet for other apps that also can be applied to Jellyfin.


RE: Hardware Transcoding - tmsrxzar - 2023-11-14

"FFmpeg exited with code 1" means ffmpeg had an error

you could look at the ffmpeg log for at least a clue


RE: Hardware Transcoding - PapaTrotsky - 2023-11-14

(2023-11-14, 03:08 AM)tmsrxzar Wrote: "FFmpeg exited with code 1" means ffmpeg had an error

you could look at the ffmpeg log for at least a clue

Code:
/videos/3a2116c7-99fe-effa-0362-0923d3050881/hls1/main/0.ts

{"Protocol":0,"Id":"3a2116c799feeffa03620923d3050881","Path":"/data/tvshows/Top Gear (UK)/Season 1/S01E01.mkv","EncoderPath":null,"EncoderProtocol":null,"Type":0,"Container":"mkv,webm","Size":363975419,"Name":"S01E01","IsRemote":false,"ETag":"3b846e40d6c9131a699b6e24f6575312","RunTimeTicks":34548480000,"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":0,"IsoType":null,"Video3DFormat":null,"MediaStreams":[{"Codec":"mpeg4","CodecTag":"DX50","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/1000","CodecTimeBase":null,"Title":null,"VideoRange":"SDR","VideoRangeType":"SDR","VideoDoViTitle":null,"LocalizedUndefined":null,"LocalizedDefault":null,"LocalizedForced":null,"LocalizedExternal":null,"DisplayTitle":"360p MPEG4 SDR","NalLengthSize":null,"IsInterlaced":false,"IsAVC":null,"ChannelLayout":null,"BitRate":842816,"BitDepth":8,"RefFrames":1,"PacketLength":null,"Channels":null,"SampleRate":null,"IsDefault":true,"IsForced":false,"Height":328,"Width":512,"AverageFrameRate":25,"RealFrameRate":25,"Profile":null,"Type":1,"AspectRatio":"64:41","Index":0,"Score":null,"IsExternal":false,"DeliveryMethod":null,"DeliveryUrl":null,"IsExternalUrl":null,"IsTextSubtitleStream":false,"SupportsExternalStream":false,"Path":null,"PixelFormat":"yuv420p","Level":-99,"IsAnamorphic":null},{"Codec":"mp3","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/1000","CodecTimeBase":null,"Title":null,"VideoRange":null,"VideoRangeType":null,"VideoDoViTitle":null,"LocalizedUndefined":null,"LocalizedDefault":null,"LocalizedForced":null,"LocalizedExternal":null,"DisplayTitle":"MP3 - Stereo - Default","NalLengthSize":null,"IsInterlaced":false,"IsAVC":null,"ChannelLayout":"stereo","BitRate":128000,"BitDepth":null,"RefFrames":null,"PacketLength":null,"Channels":2,"SampleRate":32000,"IsDefault":true,"IsForced":false,"Height":null,"Width":null,"AverageFrameRate":null,"RealFrameRate":null,"Profile":null,"Type":0,"AspectRatio":null,"Index":1,"Score":null,"IsExternal":false,"DeliveryMethod":null,"DeliveryUrl":null,"IsExternalUrl":null,"IsTextSubtitleStream":false,"SupportsExternalStream":false,"Path":null,"PixelFormat":null,"Level":0,"IsAnamorphic":null}],"MediaAttachments":[],"Formats":[],"Bitrate":970816,"Timestamp":null,"RequiredHttpHeaders":{},"TranscodingUrl":null,"TranscodingSubProtocol":null,"TranscodingContainer":null,"AnalyzeDurationMs":null,"DefaultAudioStreamIndex":null,"DefaultSubtitleStreamIndex":null}

/usr/lib/jellyfin-ffmpeg/ffmpeg -analyzeduration 200M -f matroska,webm -autorotate 0 -i file:"/data/tvshows/Top Gear (UK)/Season 1/S01E01.mkv" -map_metadata -1 -map_chapters -1 -threads 8 -map 0:0 -map 0:1 -map -0:s -codec:v:0 libx264 -preset veryfast -crf 23 -maxrate 4214080 -bufsize 8428160 -x264opts:0 subme=0:me_range=4:rc_lookahead=10:me=dia:no_chroma_me:8x8dct=0:partitions=none -force_key_frames:0 "expr:gte(t,0+n_forced*3)" -sc_threshold:v:0 0 -vf "setparams=color_primaries=bt709:color_trc=bt709:colorspace=bt709,scale=trunc(min(max(iw\,ih*a)\,min(512\,328*a))/2)*2:trunc(min(max(iw/a\,ih)\,min(512/a\,328))/2)*2,format=yuv420p" -codec:a:0 copy -copyts -avoid_negative_ts disabled -max_muxing_queue_size 2048 -f hls -max_delay 5000000 -hls_time 3 -hls_segment_type mpegts -start_number 0 -hls_segment_filename "/config/data/transcodes/5224efccf093e9f3af71328b365bc062%d.ts" -hls_playlist_type vod -hls_list_size 0 -y "/config/data/transcodes/5224efccf093e9f3af71328b365bc062.m3u8"


ffmpeg version 5.1.3-Jellyfin Copyright (c) 2000-2022 the FFmpeg developers
  built with gcc 11 (Ubuntu 11.4.0-1ubuntu1~22.04)
  configuration: --prefix=/usr/lib/jellyfin-ffmpeg --target-os=linux --extra-libs=-lfftw3f --extra-version=Jellyfin --disable-doc --disable-ffplay --disable-ptx-compression --disable-static --disable-libxcb --disable-sdl2 --disable-xlib --enable-lto --enable-gpl --enable-version3 --enable-shared --enable-gmp --enable-gnutls --enable-chromaprint --enable-libdrm --enable-libass --enable-libfreetype --enable-libfribidi --enable-libfontconfig --enable-libbluray --enable-libmp3lame --enable-libopus --enable-libtheora --enable-libvorbis --enable-libopenmpt --enable-libdav1d --enable-libwebp --enable-libvpx --enable-libx264 --enable-libx265 --enable-libzvbi --enable-libzimg --enable-libfdk-aac --arch=amd64 --enable-libsvtav1 --enable-libshaderc --enable-libplacebo --enable-vulkan --enable-opencl --enable-vaapi --enable-amf --enable-libmfx --enable-ffnvcodec --enable-cuda --enable-cuda-llvm --enable-cuvid --enable-nvdec --enable-nvenc
  libavutil      57. 28.100 / 57. 28.100
  libavcodec    59. 37.100 / 59. 37.100
  libavformat    59. 27.100 / 59. 27.100
  libavdevice    59.  7.100 / 59.  7.100
  libavfilter    8. 44.100 /  8. 44.100
  libswscale      6.  7.100 /  6.  7.100
  libswresample  4.  7.100 /  4.  7.100
  libpostproc    56.  6.100 / 56.  6.100
Input #0, matroska,webm, from 'file:/data/tvshows/Top Gear (UK)/Season 1/S01E01.mkv':
  Metadata:
    encoder        : libebml v1.3.0 + libmatroska v1.4.1
    creation_time  : 2014-01-03T17:13:46.000000Z
  Duration: 00:57:34.85, start: 0.000000, bitrate: 842 kb/s
  Stream #0:0: Video: mpeg4 (DX50 / 0x30355844), yuv420p, 512x328 [SAR 1:1 DAR 64:41], 25 fps, 25 tbr, 1k tbn (default)
  Stream #0:1: Audio: mp3, 32000 Hz, stereo, fltp, 128 kb/s (default)
Stream mapping:
  Stream #0:0 -> #0:0 (mpeg4 (native) -> h264 (libx264))
  Stream #0:1 -> #0:1 (copy)
Press [q] to stop, [?] for help
[mpeg4 @ 0x5628f114ee40] Video uses a non-standard and wasteful way to store B-frames ('packed B-frames'). Consider using the mpeg4_unpack_bframes bitstream filter without encoding but stream copy to fix it.
[libx264 @ 0x5628f1140b80] using SAR=1/1
[libx264 @ 0x5628f1140b80] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2 AVX FMA3 BMI2 AVX2
[libx264 @ 0x5628f1140b80] profile Main, level 3.0, 4:2:0, 8-bit
[libx264 @ 0x5628f1140b80] 264 - core 163 r3060 5db6aa6 - H.264/MPEG-4 AVC codec - Copyleft 2003-2021 - http://www.videolan.org/x264.html - options: cabac=1 ref=1 deblock=1:0:0 analyse=0x1:0 me=dia subme=0 psy=1 psy_rd=1.00:0.00 mixed_ref=0 me_range=4 chroma_me=0 trellis=0 8x8dct=0 cqm=0 deadzone=21,11 fast_pskip=1 chroma_qp_offset=0 threads=8 lookahead_threads=1 sliced_threads=0 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_intra=0 bframes=3 b_pyramid=2 b_adapt=1 b_bias=0 direct=1 weightb=1 open_gop=0 weightp=1 keyint=250 keyint_min=25 scenecut=0 intra_refresh=0 rc_lookahead=10 rc=crf mbtree=1 crf=23.0 qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 vbv_maxrate=4214 vbv_bufsize=8428 crf_max=0.0 nal_hrd=none filler=0 ip_ratio=1.40 aq=1:1.00
Output #0, hls, to '/config/data/transcodes/5224efccf093e9f3af71328b365bc062.m3u8':
  Metadata:
    encoder        : Lavf59.27.100
  Stream #0:0: Video: h264, yuv420p(bt709, progressive), 512x328 [SAR 1:1 DAR 64:41], q=2-31, 25 fps, 90k tbn (default)
    Metadata:
      encoder        : Lavc59.37.100 libx264
    Side data:
      cpb: bitrate max/min/avg: 4214000/0/0 buffer size: 8428000 vbv_delay: N/A
  Stream #0:1: Audio: mp3, 32000 Hz, stereo, fltp, 128 kb/s (default)
frame=    1 fps=0.0 q=0.0 size=N/A time=00:00:00.00 bitrate=N/A speed=  0x   
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc0620.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc0621.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc0622.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc0623.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc0624.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc0625.ts' for writing
frame=  490 fps=0.0 q=28.0 size=N/A time=00:00:19.44 bitrate=N/A speed=36.9x   
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc0626.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc0627.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc0628.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc0629.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06210.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06211.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06212.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06213.ts' for writing
frame= 1073 fps=1043 q=28.0 size=N/A time=00:00:42.69 bitrate=N/A speed=41.5x   
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06214.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06215.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06216.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06217.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06218.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06219.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06220.ts' for writing
frame= 1650 fps=1079 q=28.0 size=N/A time=00:01:05.84 bitrate=N/A speed=43.1x   
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06221.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06222.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06223.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06224.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06225.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06226.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06227.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06228.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06229.ts' for writing
frame= 2284 fps=1125 q=28.0 size=N/A time=00:01:31.22 bitrate=N/A speed=44.9x   
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06230.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06231.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06232.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06233.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06234.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06235.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06236.ts' for writing
frame= 2850 fps=1126 q=28.0 size=N/A time=00:01:53.79 bitrate=N/A speed=  45x   
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06237.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06238.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06239.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06240.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06241.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06242.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06243.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06244.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06245.ts' for writing
frame= 3508 fps=1157 q=28.0 size=N/A time=00:02:20.07 bitrate=N/A speed=46.2x   
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06246.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06247.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06248.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06249.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06250.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06251.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06252.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06253.ts' for writing
frame= 4108 fps=1163 q=28.0 size=N/A time=00:02:44.12 bitrate=N/A speed=46.5x   
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06254.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06255.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06256.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06257.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06258.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06259.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06260.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06261.ts' for writing
frame= 4746 fps=1177 q=28.0 size=N/A time=00:03:09.61 bitrate=N/A speed=  47x   
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06262.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06263.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06264.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06265.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06266.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06267.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06268.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06269.ts' for writing
frame= 5345 fps=1179 q=28.0 size=N/A time=00:03:33.55 bitrate=N/A speed=47.1x   
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06270.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06271.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06272.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06273.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06274.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06275.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06276.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06277.ts' for writing
frame= 5888 fps=1170 q=28.0 size=N/A time=00:03:55.29 bitrate=N/A speed=46.7x   
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06278.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06279.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06280.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06281.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06282.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06283.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06284.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06285.ts' for writing
frame= 6492 fps=1173 q=28.0 size=N/A time=00:04:19.48 bitrate=N/A speed=46.9x   
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06286.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06287.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06288.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06289.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06290.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06291.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06292.ts' for writing
frame= 7072 fps=1172 q=28.0 size=N/A time=00:04:42.63 bitrate=N/A speed=46.8x   
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06293.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06294.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06295.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06296.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06297.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06298.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc06299.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc062100.ts' for writing
frame= 7672 fps=1174 q=28.0 size=N/A time=00:05:06.68 bitrate=N/A speed=46.9x   
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc062101.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc062102.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc062103.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc062104.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc062105.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc062106.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc062107.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc062108.ts' for writing
frame= 8270 fps=1175 q=28.0 size=N/A time=00:05:30.55 bitrate=N/A speed=  47x   
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc062109.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc062110.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc062111.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc062112.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc062113.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc062114.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc062115.ts' for writing
frame= 8795 fps=1167 q=28.0 size=N/A time=00:05:51.64 bitrate=N/A speed=46.7x   
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc062116.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc062117.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc062118.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc062119.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc062120.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc062121.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc062122.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc062123.ts' for writing
frame= 9365 fps=1165 q=28.0 size=N/A time=00:06:14.40 bitrate=N/A speed=46.6x   
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc062124.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc062125.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc062126.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc062127.ts' for writing
[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc062128.ts' for writing


[q] command received. Exiting.

[hls @ 0x5628f1144c40] Opening '/config/data/transcodes/5224efccf093e9f3af71328b365bc062129.ts' for writing
frame= 9706 fps=1161 q=-1.0 Lsize=N/A time=00:06:28.11 bitrate=N/A speed=46.4x   
video:36679kB audio:4867kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: unknown
[libx264 @ 0x5628f1140b80] frame I:130  Avg QP:21.06  size: 19165
[libx264 @ 0x5628f1140b80] frame P:3430  Avg QP:24.54  size:  6948
[libx264 @ 0x5628f1140b80] frame B:6146  Avg QP:28.55  size:  1828
[libx264 @ 0x5628f1140b80] consecutive B-frames:  9.2% 16.3%  8.0% 66.4%
[libx264 @ 0x5628f1140b80] mb I  I16..4: 12.2%  0.0% 87.8%
[libx264 @ 0x5628f1140b80] mb P  I16..4: 16.8%  0.0%  0.0%  P16..4: 69.3%  0.0%  0.0%  0.0%  0.0%    skip:13.9%
[libx264 @ 0x5628f1140b80] mb B  I16..4:  2.3%  0.0%  0.0%  B16..8: 32.7%  0.0%  0.0%  direct:12.4%  skip:52.6%  L0:33.7% L1:38.3% BI:27.9%
[libx264 @ 0x5628f1140b80] coded y,uvDC,uvAC intra: 57.2% 61.0% 25.1% inter: 23.1% 16.4% 1.3%
[libx264 @ 0x5628f1140b80] i16 v,h,dc,p: 24% 43% 17% 15%
[libx264 @ 0x5628f1140b80] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 22% 30%  9%  7%  6%  5%  7%  5% 10%
[libx264 @ 0x5628f1140b80] i8c dc,h,v,p: 32% 37% 20% 11%
[libx264 @ 0x5628f1140b80] Weighted P-Frames: Y:5.5% UV:3.0%
[libx264 @ 0x5628f1140b80] kb/s:773.92



RE: Hardware Transcoding - TheDreadPirate - 2023-11-14

This looks like a log when you had NVENC disabled. Can you share an ffmpeg_transcode log from when you had NVENC enabled?


RE: Hardware Transcoding - PapaTrotsky - 2023-11-14

(2023-11-14, 05:27 PM)TheDreadPirate Wrote: This looks like a log when you had NVENC disabled.  Can you share an ffmpeg_transcode log from when you had NVENC enabled?

It generated 3 logs so gonna add 3 sets of logs here, in the order they were generated. It looks like GPU isn't starting but I can't figure out why, I followed the install guides to the best of my ability and it seemed like it worked.

Code:
/videos/fd3d0ce9-c69a-edf1-cb64-d946fe37ac7c/hls1/main/0.ts

{"Protocol":0,"Id":"fd3d0ce9c69aedf1cb64d946fe37ac7c","Path":"/data/tvshows/Top Gear (UK)/Season 1/S01E03.mkv","EncoderPath":null,"EncoderProtocol":null,"Type":0,"Container":"mkv,webm","Size":598081088,"Name":"S01E03","IsRemote":false,"ETag":"531cab20f17959311ef3bab7dbe908af","RunTimeTicks":33839599616,"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":0,"IsoType":null,"Video3DFormat":null,"MediaStreams":[{"Codec":"mpeg4","CodecTag":"XVID","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/1000","CodecTimeBase":null,"Title":null,"VideoRange":"SDR","VideoRangeType":"SDR","VideoDoViTitle":null,"LocalizedUndefined":null,"LocalizedDefault":null,"LocalizedForced":null,"LocalizedExternal":null,"DisplayTitle":"360p MPEG4 SDR","NalLengthSize":null,"IsInterlaced":false,"IsAVC":null,"ChannelLayout":null,"BitRate":1413919,"BitDepth":8,"RefFrames":1,"PacketLength":null,"Channels":null,"SampleRate":null,"IsDefault":true,"IsForced":false,"Height":256,"Width":384,"AverageFrameRate":25,"RealFrameRate":25,"Profile":"Advanced Simple Profile","Type":1,"AspectRatio":"1.5:1","Index":0,"Score":null,"IsExternal":false,"DeliveryMethod":null,"DeliveryUrl":null,"IsExternalUrl":null,"IsTextSubtitleStream":false,"SupportsExternalStream":false,"Path":null,"PixelFormat":"yuv420p","Level":5,"IsAnamorphic":null},{"Codec":"mp3","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/1000","CodecTimeBase":null,"Title":null,"VideoRange":null,"VideoRangeType":null,"VideoDoViTitle":null,"LocalizedUndefined":null,"LocalizedDefault":null,"LocalizedForced":null,"LocalizedExternal":null,"DisplayTitle":"MP3 - Stereo - Default","NalLengthSize":null,"IsInterlaced":false,"IsAVC":null,"ChannelLayout":"stereo","BitRate":56000,"BitDepth":null,"RefFrames":null,"PacketLength":null,"Channels":2,"SampleRate":24000,"IsDefault":true,"IsForced":false,"Height":null,"Width":null,"AverageFrameRate":null,"RealFrameRate":null,"Profile":null,"Type":0,"AspectRatio":null,"Index":1,"Score":null,"IsExternal":false,"DeliveryMethod":null,"DeliveryUrl":null,"IsExternalUrl":null,"IsTextSubtitleStream":false,"SupportsExternalStream":false,"Path":null,"PixelFormat":null,"Level":0,"IsAnamorphic":null}],"MediaAttachments":[],"Formats":[],"Bitrate":1469919,"Timestamp":null,"RequiredHttpHeaders":{},"TranscodingUrl":null,"TranscodingSubProtocol":null,"TranscodingContainer":null,"AnalyzeDurationMs":null,"DefaultAudioStreamIndex":null,"DefaultSubtitleStreamIndex":null}

/usr/lib/jellyfin-ffmpeg/ffmpeg -analyzeduration 200M -init_hw_device cuda=cu:0 -filter_hw_device cu -autorotate 0 -i file:"/data/tvshows/Top Gear (UK)/Season 1/S01E03.mkv" -map_metadata -1 -map_chapters -1 -threads 8 -map 0:0 -map 0:1 -map -0:s -codec:v:0 h264_nvenc -preset p1 -b:v 3534798 -maxrate 3534798 -bufsize 7069596 -g:v:0 75 -keyint_min:v:0 75 -vf "setparams=color_primaries=bt709:color_trc=bt709:colorspace=bt709,scale=trunc(min(max(iw\,ih*a)\,min(384\,256*a))/2)*2:trunc(min(max(iw/a\,ih)\,min(384/a\,256))/2)*2,format=yuv420p" -codec:a:0 copy -copyts -avoid_negative_ts disabled -max_muxing_queue_size 2048 -f hls -max_delay 5000000 -hls_time 3 -hls_segment_type mpegts -start_number 0 -hls_segment_filename "/config/data/transcodes/c72e1905200bbbfc2346cbfd3aff94cd%d.ts" -hls_playlist_type vod -hls_list_size 0 -y "/config/data/transcodes/c72e1905200bbbfc2346cbfd3aff94cd.m3u8"


ffmpeg version 5.1.3-Jellyfin Copyright (c) 2000-2022 the FFmpeg developers
  built with gcc 11 (Ubuntu 11.4.0-1ubuntu1~22.04)
  configuration: --prefix=/usr/lib/jellyfin-ffmpeg --target-os=linux --extra-libs=-lfftw3f --extra-version=Jellyfin --disable-doc --disable-ffplay --disable-ptx-compression --disable-static --disable-libxcb --disable-sdl2 --disable-xlib --enable-lto --enable-gpl --enable-version3 --enable-shared --enable-gmp --enable-gnutls --enable-chromaprint --enable-libdrm --enable-libass --enable-libfreetype --enable-libfribidi --enable-libfontconfig --enable-libbluray --enable-libmp3lame --enable-libopus --enable-libtheora --enable-libvorbis --enable-libopenmpt --enable-libdav1d --enable-libwebp --enable-libvpx --enable-libx264 --enable-libx265 --enable-libzvbi --enable-libzimg --enable-libfdk-aac --arch=amd64 --enable-libsvtav1 --enable-libshaderc --enable-libplacebo --enable-vulkan --enable-opencl --enable-vaapi --enable-amf --enable-libmfx --enable-ffnvcodec --enable-cuda --enable-cuda-llvm --enable-cuvid --enable-nvdec --enable-nvenc
  libavutil      57. 28.100 / 57. 28.100
  libavcodec    59. 37.100 / 59. 37.100
  libavformat    59. 27.100 / 59. 27.100
  libavdevice    59.  7.100 / 59.  7.100
  libavfilter    8. 44.100 /  8. 44.100
  libswscale      6.  7.100 /  6.  7.100
  libswresample  4.  7.100 /  4.  7.100
  libpostproc    56.  6.100 / 56.  6.100
[AVHWDeviceContext @ 0x55fe699597c0] Cannot load libcuda.so.1
[AVHWDeviceContext @ 0x55fe699597c0] Could not dynamically load CUDA
Device creation failed: -1.
Failed to set value 'cuda=cu:0' for option 'init_hw_device': Operation not permitted
Error parsing global options: Operation not permitted

Code:
/videos/fd3d0ce9-c69a-edf1-cb64-d946fe37ac7c/hls1/main/0.ts

{"Protocol":0,"Id":"fd3d0ce9c69aedf1cb64d946fe37ac7c","Path":"/data/tvshows/Top Gear (UK)/Season 1/S01E03.mkv","EncoderPath":null,"EncoderProtocol":null,"Type":0,"Container":"mkv,webm","Size":598081088,"Name":"S01E03","IsRemote":false,"ETag":"531cab20f17959311ef3bab7dbe908af","RunTimeTicks":33839599616,"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":0,"IsoType":null,"Video3DFormat":null,"MediaStreams":[{"Codec":"mpeg4","CodecTag":"XVID","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/1000","CodecTimeBase":null,"Title":null,"VideoRange":"SDR","VideoRangeType":"SDR","VideoDoViTitle":null,"LocalizedUndefined":null,"LocalizedDefault":null,"LocalizedForced":null,"LocalizedExternal":null,"DisplayTitle":"360p MPEG4 SDR","NalLengthSize":null,"IsInterlaced":false,"IsAVC":null,"ChannelLayout":null,"BitRate":1413919,"BitDepth":8,"RefFrames":1,"PacketLength":null,"Channels":null,"SampleRate":null,"IsDefault":true,"IsForced":false,"Height":256,"Width":384,"AverageFrameRate":25,"RealFrameRate":25,"Profile":"Advanced Simple Profile","Type":1,"AspectRatio":"1.5:1","Index":0,"Score":null,"IsExternal":false,"DeliveryMethod":null,"DeliveryUrl":null,"IsExternalUrl":null,"IsTextSubtitleStream":false,"SupportsExternalStream":false,"Path":null,"PixelFormat":"yuv420p","Level":5,"IsAnamorphic":null},{"Codec":"mp3","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/1000","CodecTimeBase":null,"Title":null,"VideoRange":null,"VideoRangeType":null,"VideoDoViTitle":null,"LocalizedUndefined":null,"LocalizedDefault":null,"LocalizedForced":null,"LocalizedExternal":null,"DisplayTitle":"MP3 - Stereo - Default","NalLengthSize":null,"IsInterlaced":false,"IsAVC":null,"ChannelLayout":"stereo","BitRate":56000,"BitDepth":null,"RefFrames":null,"PacketLength":null,"Channels":2,"SampleRate":24000,"IsDefault":true,"IsForced":false,"Height":null,"Width":null,"AverageFrameRate":null,"RealFrameRate":null,"Profile":null,"Type":0,"AspectRatio":null,"Index":1,"Score":null,"IsExternal":false,"DeliveryMethod":null,"DeliveryUrl":null,"IsExternalUrl":null,"IsTextSubtitleStream":false,"SupportsExternalStream":false,"Path":null,"PixelFormat":null,"Level":0,"IsAnamorphic":null}],"MediaAttachments":[],"Formats":[],"Bitrate":1469919,"Timestamp":null,"RequiredHttpHeaders":{},"TranscodingUrl":null,"TranscodingSubProtocol":null,"TranscodingContainer":null,"AnalyzeDurationMs":null,"DefaultAudioStreamIndex":null,"DefaultSubtitleStreamIndex":null}

/usr/lib/jellyfin-ffmpeg/ffmpeg -analyzeduration 200M -init_hw_device cuda=cu:0 -filter_hw_device cu -autorotate 0 -i file:"/data/tvshows/Top Gear (UK)/Season 1/S01E03.mkv" -map_metadata -1 -map_chapters -1 -threads 8 -map 0:0 -map 0:1 -map -0:s -codec:v:0 h264_nvenc -preset p1 -b:v 3534798 -maxrate 3534798 -bufsize 7069596 -g:v:0 75 -keyint_min:v:0 75 -vf "setparams=color_primaries=bt709:color_trc=bt709:colorspace=bt709,scale=trunc(min(max(iw\,ih*a)\,min(384\,256*a))/2)*2:trunc(min(max(iw/a\,ih)\,min(384/a\,256))/2)*2,format=yuv420p" -codec:a:0 libmp3lame -ac 2 -ab 56000 -ar 24000 -copyts -avoid_negative_ts disabled -max_muxing_queue_size 2048 -f hls -max_delay 5000000 -hls_time 3 -hls_segment_type mpegts -start_number 0 -hls_segment_filename "/config/data/transcodes/ba508827470d864ec017acfe133a4ebb%d.ts" -hls_playlist_type vod -hls_list_size 0 -y "/config/data/transcodes/ba508827470d864ec017acfe133a4ebb.m3u8"


ffmpeg version 5.1.3-Jellyfin Copyright (c) 2000-2022 the FFmpeg developers
  built with gcc 11 (Ubuntu 11.4.0-1ubuntu1~22.04)
  configuration: --prefix=/usr/lib/jellyfin-ffmpeg --target-os=linux --extra-libs=-lfftw3f --extra-version=Jellyfin --disable-doc --disable-ffplay --disable-ptx-compression --disable-static --disable-libxcb --disable-sdl2 --disable-xlib --enable-lto --enable-gpl --enable-version3 --enable-shared --enable-gmp --enable-gnutls --enable-chromaprint --enable-libdrm --enable-libass --enable-libfreetype --enable-libfribidi --enable-libfontconfig --enable-libbluray --enable-libmp3lame --enable-libopus --enable-libtheora --enable-libvorbis --enable-libopenmpt --enable-libdav1d --enable-libwebp --enable-libvpx --enable-libx264 --enable-libx265 --enable-libzvbi --enable-libzimg --enable-libfdk-aac --arch=amd64 --enable-libsvtav1 --enable-libshaderc --enable-libplacebo --enable-vulkan --enable-opencl --enable-vaapi --enable-amf --enable-libmfx --enable-ffnvcodec --enable-cuda --enable-cuda-llvm --enable-cuvid --enable-nvdec --enable-nvenc
  libavutil      57. 28.100 / 57. 28.100
  libavcodec    59. 37.100 / 59. 37.100
  libavformat    59. 27.100 / 59. 27.100
  libavdevice    59.  7.100 / 59.  7.100
  libavfilter    8. 44.100 /  8. 44.100
  libswscale      6.  7.100 /  6.  7.100
  libswresample  4.  7.100 /  4.  7.100
  libpostproc    56.  6.100 / 56.  6.100
[AVHWDeviceContext @ 0x556ad06a1900] Cannot load libcuda.so.1
[AVHWDeviceContext @ 0x556ad06a1900] Could not dynamically load CUDA
Device creation failed: -1.
Failed to set value 'cuda=cu:0' for option 'init_hw_device': Operation not permitted
Error parsing global options: Operation not permitted

Code:
/videos/fd3d0ce9-c69a-edf1-cb64-d946fe37ac7c/hls1/main/0.ts

{"Protocol":0,"Id":"fd3d0ce9c69aedf1cb64d946fe37ac7c","Path":"/data/tvshows/Top Gear (UK)/Season 1/S01E03.mkv","EncoderPath":null,"EncoderProtocol":null,"Type":0,"Container":"mkv,webm","Size":598081088,"Name":"S01E03","IsRemote":false,"ETag":"531cab20f17959311ef3bab7dbe908af","RunTimeTicks":33839599616,"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":0,"IsoType":null,"Video3DFormat":null,"MediaStreams":[{"Codec":"mpeg4","CodecTag":"XVID","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/1000","CodecTimeBase":null,"Title":null,"VideoRange":"SDR","VideoRangeType":"SDR","VideoDoViTitle":null,"LocalizedUndefined":null,"LocalizedDefault":null,"LocalizedForced":null,"LocalizedExternal":null,"DisplayTitle":"360p MPEG4 SDR","NalLengthSize":null,"IsInterlaced":false,"IsAVC":null,"ChannelLayout":null,"BitRate":1413919,"BitDepth":8,"RefFrames":1,"PacketLength":null,"Channels":null,"SampleRate":null,"IsDefault":true,"IsForced":false,"Height":256,"Width":384,"AverageFrameRate":25,"RealFrameRate":25,"Profile":"Advanced Simple Profile","Type":1,"AspectRatio":"1.5:1","Index":0,"Score":null,"IsExternal":false,"DeliveryMethod":null,"DeliveryUrl":null,"IsExternalUrl":null,"IsTextSubtitleStream":false,"SupportsExternalStream":false,"Path":null,"PixelFormat":"yuv420p","Level":5,"IsAnamorphic":null},{"Codec":"mp3","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/1000","CodecTimeBase":null,"Title":null,"VideoRange":null,"VideoRangeType":null,"VideoDoViTitle":null,"LocalizedUndefined":null,"LocalizedDefault":null,"LocalizedForced":null,"LocalizedExternal":null,"DisplayTitle":"MP3 - Stereo - Default","NalLengthSize":null,"IsInterlaced":false,"IsAVC":null,"ChannelLayout":"stereo","BitRate":56000,"BitDepth":null,"RefFrames":null,"PacketLength":null,"Channels":2,"SampleRate":24000,"IsDefault":true,"IsForced":false,"Height":null,"Width":null,"AverageFrameRate":null,"RealFrameRate":null,"Profile":null,"Type":0,"AspectRatio":null,"Index":1,"Score":null,"IsExternal":false,"DeliveryMethod":null,"DeliveryUrl":null,"IsExternalUrl":null,"IsTextSubtitleStream":false,"SupportsExternalStream":false,"Path":null,"PixelFormat":null,"Level":0,"IsAnamorphic":null}],"MediaAttachments":[],"Formats":[],"Bitrate":1469919,"Timestamp":null,"RequiredHttpHeaders":{},"TranscodingUrl":null,"TranscodingSubProtocol":null,"TranscodingContainer":null,"AnalyzeDurationMs":null,"DefaultAudioStreamIndex":null,"DefaultSubtitleStreamIndex":null}

/usr/lib/jellyfin-ffmpeg/ffmpeg -analyzeduration 200M -init_hw_device cuda=cu:0 -filter_hw_device cu -autorotate 0 -i file:"/data/tvshows/Top Gear (UK)/Season 1/S01E03.mkv" -map_metadata -1 -map_chapters -1 -threads 8 -map 0:0 -map 0:1 -map -0:s -codec:v:0 h264_nvenc -preset p1 -b:v 3534798 -maxrate 3534798 -bufsize 7069596 -g:v:0 75 -keyint_min:v:0 75 -vf "setparams=color_primaries=bt709:color_trc=bt709:colorspace=bt709,scale=trunc(min(max(iw\,ih*a)\,min(384\,256*a))/2)*2:trunc(min(max(iw/a\,ih)\,min(384/a\,256))/2)*2,format=yuv420p" -codec:a:0 copy -copyts -avoid_negative_ts disabled -max_muxing_queue_size 2048 -f hls -max_delay 5000000 -hls_time 3 -hls_segment_type mpegts -start_number 0 -hls_segment_filename "/config/data/transcodes/5bd406311c2bcebf449b91034121953c%d.ts" -hls_playlist_type vod -hls_list_size 0 -y "/config/data/transcodes/5bd406311c2bcebf449b91034121953c.m3u8"


ffmpeg version 5.1.3-Jellyfin Copyright (c) 2000-2022 the FFmpeg developers
  built with gcc 11 (Ubuntu 11.4.0-1ubuntu1~22.04)
  configuration: --prefix=/usr/lib/jellyfin-ffmpeg --target-os=linux --extra-libs=-lfftw3f --extra-version=Jellyfin --disable-doc --disable-ffplay --disable-ptx-compression --disable-static --disable-libxcb --disable-sdl2 --disable-xlib --enable-lto --enable-gpl --enable-version3 --enable-shared --enable-gmp --enable-gnutls --enable-chromaprint --enable-libdrm --enable-libass --enable-libfreetype --enable-libfribidi --enable-libfontconfig --enable-libbluray --enable-libmp3lame --enable-libopus --enable-libtheora --enable-libvorbis --enable-libopenmpt --enable-libdav1d --enable-libwebp --enable-libvpx --enable-libx264 --enable-libx265 --enable-libzvbi --enable-libzimg --enable-libfdk-aac --arch=amd64 --enable-libsvtav1 --enable-libshaderc --enable-libplacebo --enable-vulkan --enable-opencl --enable-vaapi --enable-amf --enable-libmfx --enable-ffnvcodec --enable-cuda --enable-cuda-llvm --enable-cuvid --enable-nvdec --enable-nvenc
  libavutil      57. 28.100 / 57. 28.100
  libavcodec    59. 37.100 / 59. 37.100
  libavformat    59. 27.100 / 59. 27.100
  libavdevice    59.  7.100 / 59.  7.100
  libavfilter    8. 44.100 /  8. 44.100
  libswscale      6.  7.100 /  6.  7.100
  libswresample  4.  7.100 /  4.  7.100
  libpostproc    56.  6.100 / 56.  6.100
[AVHWDeviceContext @ 0x56119982a7c0] Cannot load libcuda.so.1
[AVHWDeviceContext @ 0x56119982a7c0] Could not dynamically load CUDA
Device creation failed: -1.
Failed to set value 'cuda=cu:0' for option 'init_hw_device': Operation not permitted
Error parsing global options: Operation not permitted



RE: Hardware Transcoding - tmsrxzar - 2023-11-14

"Failed to set value 'cuda=cu:0' for option 'init_hw_device': Operation not permitted"

see if the answer is here https://github.com/jellyfin/jellyfin/issues/7036


RE: Hardware Transcoding - TheDreadPirate - 2023-11-14

Did you find any guides to help you ensure the container has access to the GPU?

https://www.reddit.com/r/unRAID/comments/wkchyv/requesting_help_with_jellyfin_nvenc_transcoding/


RE: Hardware Transcoding - PapaTrotsky - 2023-11-14

(2023-11-14, 08:47 PM)tmsrxzar Wrote: "Failed to set value 'cuda=cu:0' for option 'init_hw_device': Operation not permitted"

see if the answer is here https://github.com/jellyfin/jellyfin/issues/7036

I tried this and adding the parameters as environmental variables but it didn't seem to work I'll try it again shortly. Or is there another way to do it instead of environmental variables? unRaid doesn't really use the command line for docker with few exceptions.


RE: Hardware Transcoding - tmsrxzar - 2023-11-14

i would like to help more but that was just what i found that was related to your issue

i use debian, lscr.io/linuxserver/jellyfin:latest, intel graphics and portainer to manage docker

there are no parallels i can draw from that will help you