Jellyfin Forum
GFX1150 - Hardware acceleration transcoding error - 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: GFX1150 - Hardware acceleration transcoding error (/t-gfx1150-hardware-acceleration-transcoding-error)



GFX1150 - Hardware acceleration transcoding error - nycom83 - 2025-05-21

Hello,

When I enable hardware acceleration for transcoding, the transcoding stops working. All settings are correctly configured.
I'm getting an error when trying to play a media file that requires transcoding.

It seems that '-init_hw_device vaapi=amdConfused-facedev/dri/renderD128' is not added when trying to transcode the file.

Quote:Environment:

- OS: Debian 12
- Linux Kernel: 6.12.25
- Virtualization: Docker
- FFmpeg Version: 7.1.1-Jellyfin
- Playback Method: web
- Hardware Acceleration: Yes
- GPU Model:  AMD Radeon Graphics (RADV GFX1150)
- Plugins: Default
- Reverse Proxy: Traefik
- Jellyfin version: 10.10.7

Quote:Jellyfin logs:

Jellyfin.Api.Helpers.MediaInfoHelper: User policy for "tit". EnablePlaybackRemuxing: True EnableVideoPlaybackTranscoding: True EnableAudioPlaybackTranscoding: True
[2025-05-12 19:46:49.382 +02:00] [INF] [313] Jellyfin.Api.Controllers.DynamicHlsController: Current HLS implementation doesn't support non-keyframe breaks but one is requested, ignoring that request
[2025-05-12 19:46:49.385 +02:00] [INF] [313] MediaBrowser.MediaEncoding.Transcoding.TranscodeManager: "/usr/lib/jellyfin-ffmpeg/ffmpeg" "-analyzeduration 200M -probesize 1G -f avi  -i file:\"/media/Séries/Tom Sawyer/(D A) Tom Sawyer L'Intégrale ( DVD Rip Fr by Tête d'eMule ) épisode 1.AVI\" -map_metadata -1 -map_chapters -1 -threads 0 -map 0:0 -map 0:1 -map -0:s -codec:v:0 h264_vaapi -rc_mode VBR -b:v 4151870 -maxrate 4151870 -bufsize 8303740 -profile:v:0 high -sei -a53_cc -force_key_frames:0 \"expr:gte(t,n_forced*3)\" -vf \"setparams=color_primaries=bt709:color_trc=bt709:colorspace=bt709,scale=trunc(min(max(iw\,ih*a)\,min(720\,576*a))/2)*2:trunc(min(max(iw/a\,ih)\,min(720/a\,576))/2)*2,format=nv12,hwupload=derive_device=vaapi\" -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 \"/cache/transcodes/e64c51edfe76fb8cc12451b64440be02%d.ts\" -hls_playlist_type vod -hls_list_size 0 -y \"/cache/transcodes/e64c51edfe76fb8cc12451b64440be02.m3u8\""
[2025-05-12 19:46:50.036 +02:00] [ERR] [54] MediaBrowser.MediaEncoding.Transcoding.TranscodeManager: FFmpeg exited with code 234
[2025-05-12 19:46:50.100 +02:00] [ERR] [54] Jellyfin.Api.Middleware.ExceptionMiddleware: Error processing request. URL "GET" "/videos/b999c3e2-26fe-f77e-9db4-794778826eec/hls1/main/0.ts".
MediaBrowser.Common.FfmpegException: FFmpeg exited with code 234
  at MediaBrowser.MediaEncoding.Transcoding.TranscodeManager.StartFfMpeg(StreamState state, String outputPath, String commandLineArguments, Guid userId, 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, Nullable1 static, String params, String tag, String deviceProfileId, String playSessionId, String segmentContainer, Nullable1 segmentLength, Nullable1 minSegments, String mediaSourceId, String deviceId, String audioCodec, Nullable1 enableAutoStreamCopy, Nullable1 allowVideoStreamCopy, Nullable1 allowAudioStreamCopy, Nullable1 breakOnNonKeyFrames, Nullable1 audioSampleRate, Nullable1 maxAudioBitDepth, Nullable1 audioBitRate, Nullable1 audioChannels, Nullable1 maxAudioChannels, String profile, String level, Nullable1 framerate, Nullable1 maxFramerate, Nullable1 copyTimestamps, Nullable1 startTimeTicks, Nullable1 width, Nullable1 height, Nullable1 maxWidth, Nullable1 maxHeight, Nullable1 videoBitRate, Nullable1 subtitleStreamIndex, Nullable1 subtitleMethod, Nullable1 maxRefFrames, Nullable1 maxVideoBitDepth, Nullable1 requireAvc, Nullable1 deInterlace, Nullable1 requireNonAnamorphic, Nullable1 transcodingMaxAudioChannels, Nullable1 cpuCoreLimit, String liveStreamId, Nullable1 enableMpegtsM2TsMode, String videoCodec, String subtitleCodec, String transcodeReasons, Nullable1 audioStreamIndex, Nullable1 videoStreamIndex, Nullable1 context, Dictionary2 streamOptions, Boolean enableAudioVbrEncoding, Boolean alwaysBurnInSubtitleWhenTranscoding)
  at lambda_method1243(Closure, Object)
  at Microsoft.AspNetCore.Mvc.Infrastructure.ActionMethodExecutor.TaskOfActionResultExecutor.Execute(ActionContext actionContext, 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 Jellyfin.Api.Middleware.ServerStartupMessageMiddleware.Invoke(HttpContext httpContext, IServerApplicationHost serverApplicationHost, ILocalizationManager localizationManager)
  at Jellyfin.Api.Middleware.WebSocketHandlerMiddleware.Invoke(HttpContext httpContext, IWebSocketManager webSocketManager)
  at Jellyfin.Api.Middleware.IPBasedAccessValidationMiddleware.Invoke(HttpContext httpContext, INetworkManager networkManager)
  at Jellyfin.Api.Middleware.LanFilteringMiddleware.Invoke(HttpContext httpContext, INetworkManager networkManager, IServerConfigurationManager serverConfigurationManager)
  at Microsoft.AspNetCore.Authorization.AuthorizationMiddleware.Invoke(HttpContext context)
  at Jellyfin.Api.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.Api.Middleware.RobotsRedirectionMiddleware.Invoke(HttpContext httpContext)
  at Jellyfin.Api.Middleware.LegacyEmbyRouteRewriteMiddleware.Invoke(HttpContext httpContext)
  at Microsoft.AspNetCore.ResponseCompression.ResponseCompressionMiddleware.InvokeCore(HttpContext context)
  at Jellyfin.Api.Middleware.ResponseTimeMiddleware.Invoke(HttpContext context, IServerConfigurationManager serverConfigurationManager)
  at Jellyfin.Api.Middleware.ExceptionMiddleware.Invoke(HttpContext context)

Quote:FFmpeg logs:

{"Protocol":0,"Id":"b999c3e226fef77e9db4794778826eec","Path":"/media/S\u00E9ries/Tom Sawyer/(D A) Tom Sawyer L\u0027Int\u00E9grale ( DVD Rip Fr by T\u00EAte d\u0027eMule ) \u00E9pisode 1.AVI","EncoderPath":null,"EncoderProtocol":null,"Type":0,"Container":"avi","Size":183390208,"Name":"(D A) Tom Sawyer L\u0027Int\u00E9grale ( DVD Rip Fr by T\u00EAte d\u0027eMule ) \u00E9pisode 1","IsRemote":false,"ETag":"9060e0c3a0447c1a061eacf9692b26c8","RunTimeTicks":14242000000,"ReadAtNativeFramerate":false,"IgnoreDts":false,"IgnoreIndex":false,"GenPtsInput":false,"SupportsTranscoding":true,"SupportsDirectStream":true,"SupportsDirectPlay":true,"IsInfiniteStream":false,"UseMostCompatibleTranscodingProfile":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,"Rotation":null,"Comment":null,"TimeBase":"1/20","CodecTimeBase":null,"Title":null,"VideoRange":1,"VideoRangeType":1,"VideoDoViTitle":null,"AudioSpatialFormat":0,"LocalizedUndefined":null,"LocalizedDefault":null,"LocalizedForced":null,"LocalizedExternal":null,"LocalizedHearingImpaired":null,"DisplayTitle":"576p MPEG4 SDR","NalLengthSize":null,"IsInterlaced":false,"IsAVC":false,"ChannelLayout":null,"BitRate":830374,"BitDepth":8,"RefFrames":1,"PacketLength":null,"Channels":null,"SampleRate":null,"IsDefault":false,"IsForced":false,"IsHearingImpaired":false,"Height":576,"Width":720,"AverageFrameRate":20,"RealFrameRate":20,"ReferenceFrameRate":20,"Profile":null,"Type":1,"AspectRatio":"5:4","Index":0,"Score":null,"IsExternal":false,"DeliveryMethod":null,"DeliveryUrl":null,"IsExternalUrl":null,"IsTextSubtitleStream":false,"SupportsExternalStream":false,"Path":null,"PixelFormat":"yuv420p","Level":-99,"IsAnamorphic":false},{"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,"Rotation":null,"Comment":null,"TimeBase":"1/24000","CodecTimeBase":null,"Title":null,"VideoRange":0,"VideoRangeType":0,"VideoDoViTitle":null,"AudioSpatialFormat":0,"LocalizedUndefined":null,"LocalizedDefault":"Default","LocalizedForced":null,"LocalizedExternal":"External","LocalizedHearingImpaired":null,"DisplayTitle":"MP3 - Stereo","NalLengthSize":null,"IsInterlaced":false,"IsAVC":false,"ChannelLayout":"stereo","BitRate":192000,"BitDepth":null,"RefFrames":null,"PacketLength":null,"Channels":2,"SampleRate":48000,"IsDefault":false,"IsForced":false,"IsHearingImpaired":false,"Height":null,"Width":null,"AverageFrameRate":null,"RealFrameRate":null,"ReferenceFrameRate":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":1030137,"FallbackMaxStreamingBitrate":null,"Timestamp":null,"RequiredHttpHeaders":{},"TranscodingUrl":null,"TranscodingSubProtocol":0,"TranscodingContainer":null,"AnalyzeDurationMs":null,"DefaultAudioStreamIndex":null,"DefaultSubtitleStreamIndex":null,"HasSegments":false}

/usr/lib/jellyfin-ffmpeg/ffmpeg -analyzeduration 200M -probesize 1G -f avi  -i file:"/media/Séries/Tom Sawyer/(D A) Tom Sawyer L'Intégrale ( DVD Rip Fr by Tête d'eMule ) épisode 1.AVI" -map_metadata -1 -map_chapters -1 -threads 0 -map 0:0 -map 0:1 -map -0:s -codec:v:0 av1_vaapi -rc_mode VBR -b:v 4151870 -maxrate 4151870 -bufsize 8303740 -profile:v:0 main -force_key_frames:0 "expr:gte(t,n_forced*3)" -vf "setparams=color_primaries=bt709:color_trc=bt709:colorspace=bt709,scale=trunc(min(max(iw\,ih*a)\,min(720\,576*a))/2)*2:trunc(min(max(iw/a\,ih)\,min(720/a\,576))/2)*2,format=nv12,hwupload=derive_device=vaapi" -codec:a:0 libfdk_aac -ac 2 -ab 256000 -copyts -avoid_negative_ts disabled -max_muxing_queue_size 2048 -f hls -max_delay 5000000 -hls_time 3 -hls_segment_type fmp4 -hls_fmp4_init_filename "ed1be36c0b4ea6802cbf1135fad1f262-1.mp4" -start_number 0 -hls_segment_filename "/cache/transcodes/ed1be36c0b4ea6802cbf1135fad1f262%d.mp4" -hls_playlist_type vod -hls_list_size 0 -y "/cache/transcodes/ed1be36c0b4ea6802cbf1135fad1f262.m3u8"


ffmpeg version 7.1.1-Jellyfin Copyright © 2000-2025 the FFmpeg developers
  built with gcc 12 (Debian 12.2.0-14)
  configuration: --prefix=/usr/lib/jellyfin-ffmpeg --target-os=linux --extra-version=Jellyfin --disable-doc --disable-ffplay --disable-static --disable-libxcb --disable-sdl2 --disable-xlib --enable-lto=auto --enable-gpl --enable-version3 --enable-shared --enable-gmp --enable-gnutls --enable-chromaprint --enable-opencl --enable-libdrm --enable-libxml2 --enable-libass --enable-libfreetype --enable-libfribidi --enable-libfontconfig --enable-libharfbuzz --enable-libbluray --enable-libmp3lame --enable-libopus --enable-libtheora --enable-libvorbis --enable-libopenmpt --enable-libdav1d --enable-libsvtav1 --enable-libwebp --enable-libvpx --enable-libx264 --enable-libx265 --enable-libzvbi --enable-libzimg --enable-libfdk-aac --arch=amd64 --enable-libshaderc --enable-libplacebo --enable-vulkan --enable-vaapi --enable-amf --enable-libvpl --enable-ffnvcodec --enable-cuda --enable-cuda-llvm --enable-cuvid --enable-nvdec --enable-nvenc
  libavutil      59. 39.100 / 59. 39.100
  libavcodec    61. 19.101 / 61. 19.101
  libavformat    61.  7.100 / 61.  7.100
  libavdevice    61.  3.100 / 61.  3.100
  libavfilter    10.  4.100 / 10.  4.100
  libswscale      8.  3.100 /  8.  3.100
  libswresample  5.  3.100 /  5.  3.100
  libpostproc    58.  3.100 / 58.  3.100
Input #0, avi, from 'fileConfused-facemedia/Séries/Tom Sawyer/(D A) Tom Sawyer L'Intégrale ( DVD Rip Fr by Tête d'eMule ) épisode 1.AVI':
  Metadata:
    software        : VirtualDubMod 1.5.1.1a (build 1155/release)
  Duration: 00:23:44.20, start: 0.000000, bitrate: 1030 kb/s
  Stream #0:0: Video: mpeg4 (XVID / 0x4449565Nerd-face, yuv420p, 720x576 [SAR 1:1 DAR 5:4], 830 kb/s, 20 fps, 20 tbr, 20 tbn
  Stream #0:1: Audio: mp3 (mp3float) (U[0][0][0] / 0x0055), 48000 Hz, stereo, fltp, 192 kb/s
Stream mapping:
  Stream #0:0 -> #0:0 (mpeg4 (native) -> av1 (av1_vaapi))
  Stream #0:1 -> #0:1 (mp3 (mp3float) -> aac (libfdk_aac))
Press [q] to stop, [?] for help
[hwupload @ 0x7f369c012940] A hardware device reference is required to upload frames to.
[Parsed_hwupload_3 @ 0x7f369c012840] Query format failed for 'Parsed_hwupload_3': Invalid argument
[vf#0:0 @ 0x55e6cdb28400] Error reinitializing filters!
[vf#0:0 @ 0x55e6cdb28400] Task finished with error code: -22 (Invalid argument)
[vf#0:0 @ 0x55e6cdb28400] Terminating thread with return code -22 (Invalid argument)
[vost#0:0/av1_vaapi @ 0x55e6cdb33d40] Could not open encoder before EOF
[vost#0:0/av1_vaapi @ 0x55e6cdb33d40] Task finished with error code: -22 (Invalid argument)
[vost#0:0/av1_vaapi @ 0x55e6cdb33d40] Terminating thread with return code -22 (Invalid argument)
[out#0/hls @ 0x55e6cdb33700] Nothing was written into output file, because at least one of its streams received no packets.
frame=    0 fps=0.0 q=0.0 Lsize=      0KiB time=N/A bitrate=N/A speed=N/A   
Conversion failed!

It seems that '-init_hw_device vaapi=amdConfused-facedev/dri/renderD128' is not added when trying to transcode the file.
If I add these parameters, the media is transcoded
   


RE: GFX1150 - Hardware acceleration transcoding error - bitmap - 2025-05-21

Uncheck "Allow encoding to AV1". As far as I can tell, your GPU doesn't currently support AV1 encoding. I may be wrong there but finding codec support matrices can be challenging.

Okay, might've lied: https://www.x.org/wiki/RadeonFeature/#radeonvcnvideocorenexthardware

Sounds like your HWA might not be set up correctly.