Skip to content
View in the app

A better way to browse. Learn more.

Unraid

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

[Guide] Plex HW Transcoding with AMD iGPU (Ryzen 7 5700G & Similar)

Featured Replies

Hi everyone,

 

After long search of forums, reddit, discord and github finally have a working method to get AMD iGPU to work with Plex Container for HW Transcoding.

Thanks to multiple unraid members in different channels as this is a consolidated working solution from different sources.

 

Requirements

  • Plex Pass (Important)
  • AMD Processor with iGPU
  • Radeon-TOP plugin by ich777 (Enables AMD GPU for unraid)

  • GPU Statistics plugin by b3rs3rk (Helps monitoring GPU usage)

  • Unraid version 6.9.x and above

 

Steps

  1. Go to Apps > Search for Plex > Select binhex-plexpass app > Click Install
  2. Add the following variables by clicking + Add another Path, Port, Variable, Label or Device option

 

Variable 1

Config Type : Device
Name : /dev/dri
Value : /dev/dri

Variable 2

Config Type : Path
Name : /usr/share/libdrm
Container Path : /home/runner/actions-runner/_work/plex-conan/plex-conan/.conan/data/libdrm/2.4.120-0/plex/main/build/73ee780ba6ea3ef381da6e7f229c475bfaf477ca/meson-install/share/libdrm/
Host Path: /usr/share/libdrm
Access Mode: Read Only

 

 

   3.  Click Apply and wait for the docker container to be created

   4.  Open plex server page by slecting webui option

   5.  Go to Settings > Transcoder

   6.  Enable Use hardware acceleration when available & Use hardware-accelerated video encoding options

   7.  Select Cezanne [Radeon Vega Series / Radeon Vega Mobile Series] option in Hardware transcoding device drop-down menu

   8.  Click Save Changes (Maybe a restart of Container can also be done after applying changes)

   9.  Tada.! HW Encoding works

 

Was able to run 4 4k HDR/DoVi -> 1080p SDR @ 20Mbps streams or 8 1080p -> 720p streams with 5700G before Memory was full

1392295498_Screenshot2023-12-03031033.png.fc069d7ee64769a6ac691041eb672898.png

 

System Spec of the test server which is used for the guide

Processor : AMD Ryzen 7 5700G

Motherboard : MSI B550M PRO-VDH WIFI

RAM : Team Group 16 GB @ 3200 MHZ x 4 (64 GB)

Storage : 2 x 1 TB Samsung 980

               4 x 4 TB WD Blue 5400 RPM

Power Supply : Cooler Master G800 GOLD

Edited by itsmemac
Updated libdrm path

  • itsmemac changed the title to [Guide] Plex HW Transcoding with AMD iGPU (Ryzen 7 5700G & Similar)
  • 2 months later...

Thanks for this. This explains and helps fix the issue I had on my Debian server running Plex as a Container on Docker. I followed the steps to add the volume to my container and I no longer get the error and it appears that my transcoding now works as it should. I've shared this fix with someone on the Plex forums since I couldn't locate ANY mention of this anywhere on there.

  • Author
10 hours ago, DanGarion said:

Thanks for this. This explains and helps fix the issue I had on my Debian server running Plex as a Container on Docker. I followed the steps to add the volume to my container and I no longer get the error and it appears that my transcoding now works as it should. I've shared this fix with someone on the Plex forums since I couldn't locate ANY mention of this anywhere on there.

Hi,

Yes, this error fix was not documented anywhere since not many tried using AGPU for transcoding in Plex

I had to do multiple trial and error fix (including building my own plex container from scratch) before arriving at this solution

libdrm was present already in host system and simply mounting the library fixed this error and transcoding started to work without any further issues.

Though this is a temp fix for the error until image creators include this in their future images

Edited by itsmemac
add info

  • 1 month later...
  • 2 months later...

got it working with a 8700G, 2 Streams 4k to 1080 GPU Load says 14% but CPU 0-4 all spike to 70%. Plex dashboard does say HW transcoding. is this normal?

Edited by mike_2246

  • Author
9 hours ago, mike_2246 said:

got it working with a 8700G, 2 Streams 4k to 1080 GPU Load says 14% but CPU 0-4 all spike to 70%. Plex dashboard does say HW transcoding. is this normal?

Its your subtitles and audio

Both are still encoded using CPU hence there will be CPU usage even though HW encoding is used where just video encoding is offloaded to GPU

Use better subtitles format

Turn off subtitle and see the CPU usage going down

ok, Thanks. no subtitles but didn't expect audio transcoding to spike 4 cpu cores to 70% on 1 transcode. If I use my P2200 my cpu stays below 10%

  • 2 months later...
  • Author

Update : it seems the plex image was update and libdrm path is changed

If you are facing issue with AMD GPU HW Transcoding, update the path to the path from the container log file

Error will be something like this

 

Quote

/home/runner/actions-runner/_work/plex-conan/plex-conan/.conan/data/libdrm/2.4.120-0/plex/main/build/73ee780ba6ea3ef381da6e7f229c475bfaf477ca/meson-install/share/libdrm/amdgpu.ids: No such file or directory

So the container path will be

/home/runner/actions-runner/_work/plex-conan/plex-conan/.conan/data/libdrm/2.4.120-0/plex/main/build/73ee780ba6ea3ef381da6e7f229c475bfaf477ca/meson-install/share/libdrm/

Monitor your plex log and see if there is error in future and update it accordingly

Edited by itsmemac
update libdrm

  • 5 weeks later...

Thanks this worked great with my 8700G appreciated your input.

  • 2 weeks later...

Updated plex today and got the dreaded error again:

 

2025-01-22 17:44:49,081 DEBG 'plexmediaserver' stderr output:
/home/runner/actions-runner/_work/plex-conan/plex-conan/.conan/data/libdrm/2.4.120-0/plex/main/build/73ee780ba6ea3ef381da6e7f229c475bfaf477ca/meson-install/share/libdrm/amdgpu.ids: No such file or directory

 

Path in the container path is already updated to

/home/runner/actions-runner/_work/plex-conan/plex-conan/.conan/data/libdrm/2.4.120-0/sixones/update-expat/build/73ee780ba6ea3ef381da6e7f229c475bfaf477ca/meson-install/share/libdrm/

but it still throws the error up there. Any insight/help?

  • Author
34 minutes ago, MellowB said:

Updated plex today and got the dreaded error again:

 

2025-01-22 17:44:49,081 DEBG 'plexmediaserver' stderr output:
/home/runner/actions-runner/_work/plex-conan/plex-conan/.conan/data/libdrm/2.4.120-0/plex/main/build/73ee780ba6ea3ef381da6e7f229c475bfaf477ca/meson-install/share/libdrm/amdgpu.ids: No such file or directory

 

Path in the container path is already updated to

/home/runner/actions-runner/_work/plex-conan/plex-conan/.conan/data/libdrm/2.4.120-0/sixones/update-expat/build/73ee780ba6ea3ef381da6e7f229c475bfaf477ca/meson-install/share/libdrm/

but it still throws the error up there. Any insight/help?

You have the incorrect path

sixones/update-expat -> plex/main

the error message is asking for plex/main and not sixones/update-expat

Hm, then nothing really changed with the update and I wonder why I got the error again...

Either way, the other part was a missunderstanding on how this works on my part and I tried to use the path to the amdgpu.ids file in the container itself... makes more sense now and after updating the path again it works now, thanks!

  • 11 months later...

(Solved) Ok I'm not having any luck with this. It sees the GPU in my plex settings and even shows a slight spike on my GPU when I start a transcode but then drops to 0% on the GPU and CPU stays spiked.

I am using the linuxserver/plex version instead of the binhex version so not sure if maybe that's why. Also how can I tell the correct location for the libdrm folder.

Solution: Stop being stupid and realize where to get the proper folder from lol. I had the libdrm folder incorrect. Also it seems if you have the checkbox for "Use hardware-accelerated video encoding" checked it seems it might not use hardware for either the decode or the encode for some reason. My guess is because my device is set to something my iGPU can't handle. But disabling that still dropped my CPU usage drastically for a 4k to 1080 transcode. I did also have to disable the HDR tone mapping to resolve the stutter issue for 4k HDR videos.

Edited by Reallango

  • 4 months later...

Sorry to Necro but I am having issues getting this to run.

I have followed the instructions to the letter and now when I try to transcode anything, the unraid log gives a segfault (sample below)

Direct Play works perfectly.

I am using lscr.io/linuxserver/plex docker

AMD Ryzen 7 5700G with Radeon Graphics @ 3800 MHz - Build is an HL4 from 45homelab.

Where am I going wrong?

May 12 17:10:52 GibsonMini kernel: mux0:stream_seg[942897]: segfault at 54 ip 000015203239726c sp 0000152024671570 error 4 in libavformat.so.60[19626c,1520322d0000+208000] likely on CPU 0 (core 0, socket 0)

May 12 17:10:52 GibsonMini kernel: Code: 44 24 10 45 31 ed eb 22 48 83 c3 1c 48 8b 47 18 4c 8b af c8 00 00 00 4c 39 e8 44 0f 47 e8 44 2b 6f 08 49 89 ff 48 89 5c 24 10 <8b> 47 54 89 44 24 0c 85 c0 0f 88 1d 01 00 00 83 7c 24 60 00 74 3b

EDIT: A new error has been found in the Plex Server Logs: /home/runner/_work/plex-conan/plex-conan/.conan/data/libdrm/2.4.120-6/plex/main/build/678777ee2ca8706ca90cf805e0dd88235f6d7f05/meson-install/share/libdrm/amdgpu.ids: No such file or directory

EDIT2: GPU usage climbs up by a percent for a second and drops to nothing when transcoding.

Edited by urbanracer34

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.