Help with Plex hardware transcoding


Recommended Posts

 

9 hours ago, shremi said:

Sorry to bring up this thread ..... I have managed to make all of the changes in the go file and everything is up and running with the docker container however i dont have the checkbox to tick in the transcoder in plex settings yeah i switched to advanced XD how can i get this ???

 

59 minutes ago, devros said:

 

I'm not sure if this is still the case, but at one point you had to be a Plex Pass subscriber for that feature

 

Yes, hardware transcoding requires a Plex Pass subscription.  Without a Plex Pass, the hardware acceleration checkbox will not appear.

Edited by Hoopster
Link to comment
  • 1 month later...
3 hours ago, Heciruam said:

So I'm running the Binhex docker. Is the command the same?

 

Does the Binhex docker have something similar to the Extra Parameters in LSIO Plex docker?  If so, the syntax should be the same as the dev/dri parameter is the syntax that Plex wants and is not specific to the LSIO docker.

Link to comment
  • 1 month later...
On 3/8/2018 at 7:22 AM, Hoopster said:
To enable hardware transcoding in Plex, do the following:

 

This goes in the Extra Parameters in the Plex Docker config (you have to enable Advanced View on the docker edit page to see this). Note: this is for the linuxserver.io Plex docker (others Plex dockers may be different):

 

image.png.d719e3f2ba0300e500fcb3af7d3f5bb2.png

 

Also, you need some entries in your go file like this (after entering these commands in the CLI):


#Setup drivers for hardware transcoding in Plex
modprobe i915
chmod -R 777 /dev/dri

And in your Plex server Transcoder Settings page you need to enable hardware acceleration

 

image.thumb.png.9987e8e84bb16ff32bd8afd5f6d8ae3c.png

 

 

How do I make those entries to the go file?

I added the extra parameters in the docker settings and this is a screen cap with info from the console.  Thank you!

 

0636C719-3B0E-4A8F-A030-C63FE15D2C65.jpeg

Link to comment
11 hours ago, azzilla said:

How do I make those entries to the go file?

 

Open the "go" file (located in your flash drive config folder) with Notepad or any other text editor and add the indicated lines to the file. 

 

Save and reboot to make sure the go file is successfully executed with the added lines.

 

Here is my "go" file for reference (the SSH section is for my rsync backup):

 

#Setup drivers for hardware transcoding in Plex
modprobe i915
chown -R nobody:users /dev/dri
chmod -R 777 /dev/dri

# Copy SSH files back to /root/.ssh folder and set permissions for files
mkdir -p /root/.ssh
cp /boot/config/ssh/medianas_key /root/.ssh/id_rsa
cp /boot/config/ssh/known_hosts /root/.ssh/known_hosts
cat /boot/config/ssh/backupnas_key.pub > /root/.ssh/authorized_keys
chmod g-rwx,o-rwx -R /root/.ssh

#!/bin/bash
# Start the Management Utility
/usr/local/sbin/emhttp &

 

  • Like 1
Link to comment
21 hours ago, Hoopster said:

 

Open the "go" file (located in your flash drive config folder) with Notepad or any other text editor and add the indicated lines to the file. 

 

Save and reboot to make sure the go file is successfully executed with the added lines.

 

Here is my "go" file for reference (the SSH section is for my rsync backup):

 


#Setup drivers for hardware transcoding in Plex
modprobe i915
chown -R nobody:users /dev/dri
chmod -R 777 /dev/dri

# Copy SSH files back to /root/.ssh folder and set permissions for files
mkdir -p /root/.ssh
cp /boot/config/ssh/medianas_key /root/.ssh/id_rsa
cp /boot/config/ssh/known_hosts /root/.ssh/known_hosts
cat /boot/config/ssh/backupnas_key.pub > /root/.ssh/authorized_keys
chmod g-rwx,o-rwx -R /root/.ssh

#!/bin/bash
# Start the Management Utility
/usr/local/sbin/emhttp &

 

Got it working! Thanks man!

Such an improvement when transcoding. Normally when i transcoded a 1080p file CPU usage was at 20%, now it's down to around 10%

Link to comment
  • 4 weeks later...
21 hours ago, ashman70 said:

I have two E5-2650's which are Sandybridge CPU's, if I throw in an Nvidia GTX 960, can I utilize hardware transcoding?

No, unfortunately. 

 

The link below spells out the hardware transcoding requirements for Plex on a Linux platform:

 

https://support.plex.tv/articles/115002178853-using-hardware-accelerated-streaming/

 

An Intel CPU with iGPU and quick sync video support is required.

 

This note is included regarding dedicated graphics cards:

 

"If your Linux computer also has a dedicated graphics card, the video encoding acceleration of Intel Quick Sync Video may become unavailable when the GPU is in use. If your computer has an NVIDIA GPU, please install the latest Latest NVIDIA drivers for Linux to make sure that Plex can use your NVIDIA graphics card for video encoding (only) when Intel Quick Sync Video becomes unavailable."

 

Unfortuantely, unRAID does not include any NVIDIA GPU drivers.  You would have to compile your own kernel to include them.  Also, a discrete GPU can do video encoding only, no decode.

Edited by Hoopster
Link to comment
  • 1 month later...
8 minutes ago, dgwharrison said:

Hi all, just one thing, I'm finding the modprobe and chmod part of this isn't sticking over server reboots. i.e. I get it all working fine, then I power cycle the Unraid server and it doesn't work again. How do I make it persistent?

Have you entered them in your 'go' file on the flash drive as mentioned above?

 

Nothing typed at the CLI in unRAID is persistent as it is all in RAM.  Anything you want to be persistent should be in the 'go' file as that gets executed on reboot.

Link to comment
  • 3 weeks later...

I had set this up a month or so ago when I became a Plex Pass subscriber and I thought it was working but now I am seeing Plex is using software transcode and spiking my CPU.  I have an 8700K on an ASUS Prime Z-370a motherboard and no other hardware has changed.

1. Edited my "go" file

#Setup drivers for hardware transcoding in Plex
modprobe i915
chown -R nobody:users /dev/dri
chmod -R 777 /dev/dri

2. Added the following to Plex docker config for Extra Parameters

--device=/dev/dri:/dev/dri (also tried with space instead of equals because this thread has it both ways

3. Content of my /dev/dri folder

drwxrwxrwx 2 nobody users       80 Dec 22 17:17 by-path/
crw-rw---- 1 root   video 226,   0 Dec 22 17:17 card0
crwxrwxrwx 1 nobody users 226, 128 Dec 22 17:17 renderD128

4. BIOS is set for CPU Graphics as primary display

 

I can see when using HDMI cable to my monitor from Unraid that the display is using the full 2K resolution so I know the driver is working.  Just Plex docker seems to not like me.  I am using the latest linuxserver/plex docker available.

 

Anyone have any suggestions?  It was working when I originally set it up.  Not sure when it broke.  I don't transcode much but was sharing with a friend over the Internet and noticed his transcodes killing my CPU.

 

Thanks

 

 

UPDATE: FIXED - instead of adding --device=/dev/dri:/dev/dri under extra parameters, I added a device to the container with a value of /dev/dri:/dev/dri.  I was seeing through console in Plex no /dev/dri folder.  Now I see one and transcoding is showing as (hw) now.

 

Edited by nickp85
Link to comment
3 hours ago, nickp85 said:

Anyone have any suggestions?  It was working when I originally set it up.  Not sure when it broke.  I don't transcode much but was sharing with a friend over the Internet and noticed his transcodes killing my CPU.

Is the "Use hardware acceleration when available" option still selected in your Plex transcoder settings?  I have occasionally seen settings reset by docker updates.

Link to comment
How do you do when you edit the file?
Do you take out the memory o put it in another computer or shut down your server first then edit the file or do it from cli?


For Windows Use “Putty” or Terminal on Mac and SSH to your server. Type mc to open midnight commander and copy the go file to a share and edit in Notepad++ for windows or Atom on Mac. Then copy the file back to the original location. Ezpz


Skickat från min iPhone med Tapatalk
Link to comment
1 hour ago, nickp85 said:

Um why not just open the Unraid web GUI and then open a console? You guys make things difficult lol :)

takes more time to open up a web browser,punch in tower, then click on the terminal. winkey+r type in "ssh user@server" takes much less time

Edited by strike
Link to comment

I'm pretty new to Plex, but I just updated my server to a i5 2500K that shall be able to do hw encoding for Plex. I signed up for a Plex Pass and I've added "--device /dev/dri:/dev/dri" where I should, but the other commands I've only runned in the terminal, not added to some "go" file.

 

Anyhow, I get "hw" when I check in dashboard in Plex. But I also got friend that only became Plex Pass users and then got that check mark in settings to activate hw encoding. I wonder if this still is up to date info or what am I missing? Is this some kind of unraid thing to get the hw?

 

Thanks.

 

/Söder

Link to comment
9 minutes ago, soder said:

But I also got friend that only became Plex Pass users and then got that check mark in settings to activate hw encoding

Is your friend running Plex on Windows, Mac or some other non-Docker/unRAID platform? 

 

The "go" file edits are required to load the video drivers when your unRAID server is rebooted since anything you do at the unRAID command line is only modifying the OS in RAM.  If you do not add "modprobe i915" and the "chmod..." commands to the go file, the next time you reboot your server, you will no longer have hardware encoding enabled.

 

The --device /dev/dri:/dev/dri is required to pass the iGPU video device through to Plex running in a docker under Linux.

Link to comment

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...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.