Jump to content

Intel Arc A380 in Docker


J0ZAH
Go to solution Solved by Q-Droid,

Recommended Posts

J0ZAH

Hey guys, 
Looking for a little help with getting my Arc A380 working inside Docker. I have verified that the a380 works with another container and I'm not sure what I'm doing wrong with Emby. My current docker-compose looks like the following
 

services:
  emby:
    container_name: "emby"
    devices:
      - "/dev/dri/:/dev/dri/"
    entrypoint:
      - "/init"
    environment:
      - "UID=1000"
      - "GID=100"
      - "GIDLIST=100"
      - "TZ=America/New_York"
# Everything below was system added
      - "PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
      - "LANG=en_US.UTF-8"
      - "HOME=/tmp"
      - "AMDGPU_IDS=/share/libdrm/amdgpu.ids"
      - "FONTCONFIG_PATH=/etc/fonts"
      - "LD_LIBRARY_PATH=/lib:/system"
      - "LIBVA_DRIVERS_PATH=/lib/dri"
      - "OCL_ICD_VENDORS=/etc/OpenCL/vendors"
      - "PCI_IDS_PATH=/share/hwdata/pci.ids"
      - "SSL_CERT_FILE=/etc/ssl/certs/ca-certificates.crt"
      - "NVIDIA_VISIBLE_DEVICES=all"
      - "NVIDIA_DRIVER_CAPABILITIES=compute,video,utility"
      - "XDG_CACHE_HOME=/config/cache"
    hostname: "9b4f9e2fa55c"
    image: "emby/embyserver:beta"
    ipc: "private"
    labels:
      maintainer: "Emby LLC <apps@emby.media>"
    logging:
      driver: "json-file"
      options: {}
    mac_address: "02:42:ac:11:00:09"
    network_mode: "bridge"
    ports:
      - "8096:8096/tcp"
    restart: "unless-stopped"
    volumes:
      - "/data:/data"
      - "/docker_local_vol/emby_config:/config"
    working_dir: "/"

My host is running Ubuntu 22.04 on Kernel 6.5.0-1014-oem and when I list out the /dev/dri directory I can see the "renderD128" device

image.png.531944f7b0977dd5c25ac8afacc7ce69.png

Furthermore, I can see usage by using the intel-gpu-tools and running intel_gpu_top when I run a transcoding workload on Jellyfin (the other container I tested) the usage spikes, however when I'm in Emby and run a transcode I get nothing. Emby also doesn't seem to even be recognizing the GPU because when I go into the transcoding settings I get the following when selecting advanced.

image.thumb.png.9d4d037330ad70665733adf62ee34db9.png

Any help or pointers would be appreciated.  

Link to comment
Share on other sites

HI, are you able to test our dedicated ubuntu package to see how that compares?

Link to comment
Share on other sites

adminExitium

Can you try with the minimal compose example from the emby page https://hub.docker.com/r/emby/embyserver because you have a lot of custom environment variables like the LD_LIBRARY_PATH, OCL_ICD_VENDORS & LIBVA_DRIVERS_PATH that may be breaking stuff?

Also, see if removing the trailing slash in devices i.e. "/dev/dri:/dev/dri" makes any difference.

  • Agree 1
Link to comment
Share on other sites

  • Solution
Q-Droid
7 hours ago, J0ZAH said:
      - "GIDLIST=100"

Include the GIDs for video and render in this variable. If no render on your host then video.

Link to comment
Share on other sites

J0ZAH

IT WORKING (insert pod racer) 
 

2 hours ago, adminExitium said:

Can you try with the minimal compose example from the emby page https://hub.docker.com/r/emby/embyserver because you have a lot of custom environment variables like the LD_LIBRARY_PATH, OCL_ICD_VENDORS & LIBVA_DRIVERS_PATH that may be breaking stuff?

Also, see if removing the trailing slash in devices i.e. "/dev/dri:/dev/dri" makes any difference.


A lot of those variables were added by docker automatically after the container creation. All of the environment variables below were not entered into the original compose. I use portainer so I ended up exporting the current running compose for this post, sorry for the confusion. 

 

 

      - "PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
      - "LANG=en_US.UTF-8"
      - "HOME=/tmp"
      - "AMDGPU_IDS=/share/libdrm/amdgpu.ids"
      - "FONTCONFIG_PATH=/etc/fonts"
      - "LD_LIBRARY_PATH=/lib:/system"
      - "LIBVA_DRIVERS_PATH=/lib/dri"
      - "OCL_ICD_VENDORS=/etc/OpenCL/vendors"
      - "PCI_IDS_PATH=/share/hwdata/pci.ids"
      - "SSL_CERT_FILE=/etc/ssl/certs/ca-certificates.crt"
      - "NVIDIA_VISIBLE_DEVICES=all"
      - "NVIDIA_DRIVER_CAPABILITIES=compute,video,utility"
      - "XDG_CACHE_HOME=/config/cache"


Once I got the GPU to show up I went back to test and the trailing / in /dev/dri/didn't seem to affect anything. best to leave it off as I have seen the general consensus is that you don't need it.

2 hours ago, Q-Droid said:

Include the GIDs for video and render in this variable. If no render on your host then video.

This is what did the trick I added the following after searching for the correct GIDLIST I found this post 

- "GIDLIST=109"

 

 

There was also a GIDLIST=44 however I tested that and it was not needed. 
Thanks everyone for the help!

  • Like 1
  • Thanks 1
Link to comment
Share on other sites

Q-Droid

That's good that it worked but those values of 109 and 44 can be different between systems.

What you want to do is get the actual values for your system on the host:

$ ls -l /dev/dri

total 0
drwxr-xr-x 2 root root         80 Feb 24 07:54 by-path
crw-rw---- 1 root video  226,   0 Feb 24 07:54 card0
crw-rw-rw- 1 root render 226, 128 Feb 24 07:54 renderD128
 

$  getent group video
video:x:483:emby

$ getent group render
render:x:486:emby,tvheadend

Ignore the user list after the number. Then add to GIDLIST=483,486

 

  • Thanks 1
Link to comment
Share on other sites

J0ZAH

That makes sense. This is what I'm getting


image.png.c55a13b50d4c9a906dc5a66147e1307c.png

Makes sense now why 109 was working, thanks. 

  • Thanks 1
Link to comment
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
×
×
  • Create New...