Jump to content

Failed to enable hardware acceleration in docker


lyphix
Go to solution Solved by Luke,

Recommended Posts

Hi guys, I am having trouble with the hardware acceleration in docker. I'm using the integrated graphics card of the Intel N100 and the system is Ubuntu server 22.04 LTS. 

My emby is  4.7.14.0

image.png.11d6cf70df812d722de04574e0c98c5f.png

With the commands:

getent group video | cut -d: -f3, I got 44

getent group render | cut -d: -f3, I got 109

So Here is my docker compose:

emby:
    image: emby/embyserver:latest
    container_name: emby
    environment:
      - UID=1000
      - GID=100
      - GIDLIST=44,109
      - TZ=Asia/Shanghai
    volumes:
      - /root/emby/config:/config
      - /root/emby/cache:/cache
      - /root/media:/media
    devices:
      - /dev/dri:/dev/dri
    ports:
      - 8096:8096
    restart: unless-stopped

After emby started, I found several errors in hardware_detection:

Devices": [
        {
            "DeviceIndex": 0,
            "DeviceInfo": {
                "VendorName": "Intel Corporation",
                "DeviceName": "Alder Lake-N [UHD Graphics]",
                "SubsytemVendorName": "Intel Corporation",
                "VendorId": 32902,
                "DeviceId": 18129,
                "SubsytemVendorId": 32902,
                "SubsytemDeviceId": 29296,
                "DevPath": "/sys/bus/pci/devices/0000:00:02.0",
                "DrmCard": "/dev/dri/card0",
                "DrmRender": "/dev/dri/renderD128",
                "IsEnabled": 1,
                "IsBootVga": 1,
                "Error": {
                    "Number": -1,
                    "Message": "Failed to initialize VA /dev/dri/renderD128. Error -1"
                }
            }
        }
    ],

I also tried:

ffmpeg -hwaccel vaapi -hwaccel_output_format vaapi -i input.mp4 -vf 'format=nv12|vaapi,hwupload' -c:v h264_vaapi output_VAAPI.mp4

It works in Ubuntu

image.png.913e56aca80815f29761532906b90f50.png

but not in Docker:

image.png.1a5da3e524a24ac3245f34239b702178.png

Could you give me any advice?

hardware_detection-63837216517.txt

Link to comment
Share on other sites

  • 1 month later...
alturismo
On 12/5/2023 at 7:53 PM, Luke said:

Hi, are you able to try the 4.8 beta server and see how that compares? Thanks.

i can confirm, updating to the beta solved here the issue with an n100 ;)

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