anthonws

Enabling i915 for host?

26 posts in this topic

Hi all,

 

I'm trying to enable the iGPU (i915 - i5 4690K) to give Plex the possibility to transcode using QSV.

 

Can anyone provide me pointers on how to do it?

 

*-display UNCLAIMED
             description: VGA compatible controller
             product: Xeon E3-1200 v3/4th Gen Core Processor Integrated Graphics Controller
             vendor: Intel Corporation
             physical id: 2
             bus info: pci@0000:00:02.0
             version: 06
             width: 64 bits
             clock: 33MHz
             capabilities: msi pm vga_controller bus_master cap_list
             configuration: latency=0

 

I went to http://slackware.osuosl.org/slackware64-14.2/slackware64/x/ and installed the following packages:

 

mesa-11.2.2-x86_64-1.txz

libva-intel-driver-1.6.2-x86_64-1.txz

libva-1.6.2-x86_64-1.txz

libvdpau-1.1.1-x86_64-1.txz

libdrm-2.4.68-x86_64-1.txz

libXext-1.3.3-x86_64-2.txz

libX11-1.6.3-x86_64-2.txz

libXfixes-5.0.2-x86_64-1.txz

libxcb-1.11.1-x86_64-1.txz

libXau-1.0.8-x86_64-2.txz

xf86-video-intel-git_20160601_b617f80-x86_64-1.txz

 

Drivers are available in /usr/lib64/xorg/modules/dri and /usr/lib64/xorg/modules/drivers but I don't know how to properly load them (i915_dri.so and/or intel_drv.so*?).

 

Thanks a lot!

 

anthonws

 

 

 

0

Share this post


Link to post
Share on other sites

I'm trying to enable the iGPU (i915 - i5 4690K) to give Plex the possibility to transcode using QSV.

 

Can anyone provide me pointers on how to do it?

 

You would have to build the i915 kernel driver module or wait for those guys at Limetech to do it.

 

I think the user space packages would be unnecessary if you were using Plex in a Docker container: https://hub.docker.com/r/plexinc/pms-docker/

 

It sounds like we're both working on the same goal 8)

0

Share this post


Link to post
Share on other sites

I'm trying to enable the iGPU (i915 - i5 4690K) to give Plex the possibility to transcode using QSV.

 

Can anyone provide me pointers on how to do it?

 

You would have to build the i915 kernel driver module or wait for those guys at Limetech to do it.

 

I think the user space packages would be unnecessary if you were using Plex in a Docker container: https://hub.docker.com/r/plexinc/pms-docker/

 

It sounds like we're both working on the same goal 8)

 

Thanks for the feedback :)

 

So, I'm following this guide: http://www.lime-technology.com/wiki/index.php/Building_a_custom_kernel and got the kernel sources uncompressed. Looked around and there's the i915 driver that I need (/usr/src/linux-4.8.12/drivers/gpu/drm/i915).

 

And according to the guide, I've already copied the unRAID patches + the md drivers and the .config file.

 

In the .config file there's a comment line saying:

 

# CONFIG_DRM_I915 is not set

 

Should I add "CONFIG_DRM_I915=m" to it and then compile?

 

Thanks!!!

 

 

0

Share this post


Link to post
Share on other sites

 

 

Should I add "CONFIG_DRM_I915=m" to it and then compile?

 

Yes, that should work.

0

Share this post


Link to post
Share on other sites

The wiki page is a bit outdated, but take look at this script for hints to do it on current unraid.

The script downloads and installs needed packages and does everything regarding compiling and packing bzroot.

But if you don't know what you're doing, I don't advice you to use it on a production system.

 

Edit: Changed link to the correct one.

0

Share this post


Link to post
Share on other sites

The wiki page is a bit outdated, but take look at this script for hints to do it on current unraid.

The script downloads and installs needed packages and does everything regarding compiling and packing bzroot.

But if you don't know what you're doing, I don't advice you to use it on a production system.

 

That script won't work on V6.2 as it's the wrong Slackware version.  You'd need to modify the ones here.  Use the kernel compile module one first, then any of the other modules to recompress.  The kernel compile one will need some editing as it will pull a .config from our server.

0

Share this post


Link to post
Share on other sites

The wiki page is a bit outdated, but take look at this script for hints to do it on current unraid.

The script downloads and installs needed packages and does everything regarding compiling and packing bzroot.

But if you don't know what you're doing, I don't advice you to use it on a production system.

 

Edit: Changed link to the correct one.

 

Thanks for the hint!! :)

 

Edit: It's my production system, but I like to live on the edge :P LOL!

0

Share this post


Link to post
Share on other sites

The wiki page is a bit outdated, but take look at this script for hints to do it on current unraid.

The script downloads and installs needed packages and does everything regarding compiling and packing bzroot.

But if you don't know what you're doing, I don't advice you to use it on a production system.

 

That script won't work on V6.2 as it's the wrong Slackware version.  You'd need to modify the ones here.  Use the kernel compile module one first, then any of the other modules to recompress.  The kernel compile one will need some editing as it will pull a .config from our server.

 

Gotcha! I'll be using the .config file from RC6 but I'll take a look on the one from your server.

 

The scripts are really nice and they provide a lot of needed information.

 

Maybe this should be part of the wiki that I've initially pointed out.

 

Cheers!

0

Share this post


Link to post
Share on other sites

So I got to the point where things are compiled and installed. I used the kernel-module-compile.sh, removed all non-necessary sections and added variables.sh content (see script in attach).

 

AFAIK the next step is the creation of the bzImage, correct?

 

Went to "kernel" and executed "make bzImage" but got the following error:

 

make[2]: *** No rule to make target 'net/netfilter/xt_RATEEST.o', needed by 'net/netfilter/built-in.o'.  Stop.
scripts/Makefile.build:440: recipe for target 'net/netfilter' failed
make[1]: *** [net/netfilter] Error 2
Makefile:970: recipe for target 'net' failed
make: *** [net] Error 2

 

Source files exist in unRAID but apparently not on the kernel sources I downloaded :/

 

Tried copying .c and .o for xt_RATEEST from unRAID local sources but it failed to compile.

 

Oh well... One step at a time :) But if you have any hints, they are more than welcome :)

 

I wish you all an awesome New Year's Eve and an excellent 2017!!!

 

Cheers,

anthonws.

 

build_new_kernel.txt

0

Share this post


Link to post
Share on other sites

@CHBMB, @eschultz and @saarg,

 

Any guidance on how overcoming the issue I mentioned previously?

 

Thanks,

anthonws.

 

0

Share this post


Link to post
Share on other sites

Best thing to do now is take a look at the libreelec module script.  Covers making the bz files.

 

Sent from my LG-H815 using Tapatalk

 

 

0

Share this post


Link to post
Share on other sites

With 6.3.0-rc9, the i915 CONFIG was added to the kernel!!

 

I'm added some lines to the go scripts and my Plex container is now using HW acceleration!

 

Super :D Thanks!

 

anthonws

0

Share this post


Link to post
Share on other sites

Good to know -- haven't been following the 6.3 threads, but it's definitely nice to know hardware acceleration is now supported for Intel IGPs.

 

0

Share this post


Link to post
Share on other sites

With 6.3.0-rc9, the i915 CONFIG was added to the kernel!!

 

I'm added some lines to the go scripts and my Plex container is now using HW acceleration!

 

Super :D Thanks!

 

anthonws

 

hey anthonws,

please can you make a short description?

 

Many thanks!

0

Share this post


Link to post
Share on other sites

Here it goes!

 

Added to "/boot/config/go" (very first lines):

modprobe i915

chmod 777 /dev/dri/*

 

Then to the Plex docker config:

 

Extra Parameters: "--device /dev/dri:/dev/dri"

Version: "#.#.#.####-xxxxxxx"

 

Hth,

anthonws.

 

*mod* don't post plexpass version #

0

Share this post


Link to post
Share on other sites

Here it goes!

 

Added to "/boot/config/go" (very first lines):

modprobe i915

chmod 777 /dev/dri/*

 

Then to the Plex docker config:

 

Extra Parameters: "--device /dev/dri:/dev/dri"

Version: "**********"

 

Hth,

anthonws.

 

That is a plexpass only version, so I suggest you edit your post and remove it.

0

Share this post


Link to post
Share on other sites

Here it goes!

 

Added to "/boot/config/go" (very first lines):

modprobe i915

chmod 777 /dev/dri/*

 

Then to the Plex docker config:

 

Extra Parameters: "--device /dev/dri:/dev/dri"

Version: "----"

 

Hth,

anthonws.

 

Many thanks for this!!!

This should also working for Emby Docker.

I will test this.  :)

 

 

--------------------------

EDIT

 

a great feature! Thanks Limetech for adding the i915 CONFIG to the kernel.

 

0

Share this post


Link to post
Share on other sites

Posted (edited)

Damn it I was avoiding 6.3.x because of the noVNC issues.. now this will force me to try it out...again.

Edited by mr-hexen
0

Share this post


Link to post
Share on other sites

Posted (edited)

It works, had to set the docker to privileged, but it's working on my i5-4460!

 

UPDATE: and BOY does this work. I was able to stream 7 transcoded streams at once using this!

Edited by mr-hexen
0

Share this post


Link to post
Share on other sites

I have a Xeon E3-1246 v3 and would like to enable this too. Not sure I understand exactly how to enable i915 in unRAID. Do I edit the 'go' file in the flash drive under "config"?

My file currently says this

 

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

would I change it to this?

 

modprobe i915

chmod 777 /dev/d

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

 

0

Share this post


Link to post
Share on other sites
14 hours ago, djsnafu said:

I have a Xeon E3-1246 v3 and would like to enable this too. Not sure I understand exactly how to enable i915 in unRAID. Do I edit the 'go' file in the flash drive under "config"?

My file currently says this

 

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

would I change it to this?

 

#!/bin/bash

#enable module for iGPU and perms for the render device

modprobe i915

chown -R nobody:users /dev/dri

chmod -R 777 /dev/dri

 

# Start the Management Utility
/usr/local/sbin/emhttp &

 

 

See above changes in red.

1

Share this post


Link to post
Share on other sites
5 hours ago, mr-hexen said:

 

See above changes in red.

Thanks mr-hexen. Another question. Do I put nobody:users just like that? or am I suppose to put a users name there? I've never created a username.

0

Share this post


Link to post
Share on other sites
3 minutes ago, djsnafu said:

Do I put nobody:users just like that?

yes

1

Share this post


Link to post
Share on other sites

Posted (edited)

Just set this up, encodes about the same speed as using 5 cores @ 100%, this is using about 1.5 to 30% (I'd guess the higher CPU stuff is file transfers from/within plex) on a single core and the built-in Intel graphics on my Xeon E3-1265Lv3.  At quick glances, the quality appears to be the same, and my videos (when being encoded) load a solid 2-3 seconds faster on play.  

Edited by McCloud
1

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now

Copyright © 2005-2017 Lime Technology, Inc. unRAID® is a registered trademark of Lime Technology, Inc.