Passthrough GPU Hardware Acceleration

liamstears

New Member
Oct 20, 2022
8
0
1
Having trouble getting gpu passthrough to work to my VM so hope someone can help

AMD 5560u onboard graphics is what I am trying to passthrough

I've gone though the proxmox guide on how to get this going and have made great steps but not quite got it working yet

On host/proxmox:
04:00.0 VGA compatible controller [0300]: Advanced Micro Devices, Inc. [AMD/ATI] Cezanne [1002:1638] (rev c3) Subsystem: Advanced Micro Devices, Inc. [AMD/ATI] Device [1002:0123] Kernel driver in use: vfio-pci Kernel modules: amdgpu

On VM/Debian:
00:11.0 VGA compatible controller [0300]: Advanced Micro Devices, Inc. [AMD/ATI] Cezanne [1002:1638] (rev c3) Subsystem: Advanced Micro Devices, Inc. [AMD/ATI] Device [1002:0123] Kernel modules: amdgpu

VAINFO Host:
error: can't connect to X server! error: failed to initialize display

VAINFO VM:
error: XDG_RUNTIME_DIR not set in the environment. error: can't connect to X server! libva info: VA-API version 1.10.0 libva error: vaGetDriverNameByIndex() failed with unknown libva error, driver_name = (null) vaInitialize failed with error code -1 (unknown libva error),exit

ls -l /dev/dri Host:
ls: cannot access '/dev/dri': No such file or directory

ls -l /dev/dri VM:
total 0 drwxr-xr-x 2 root root 60 Apr 24 00:46 by-path crw-rw----+ 1 root video 226, 0 Apr 24 00:46 card0

I believe I need renderD128 to show up on the VM in /dev/dri before I am going to get this to work, am I right? My first task for this is to get hardware acceleration working in Frigate in a docker container on the debian VM

On host/proxmox "ls -l /dev/dri" shows nothing however is does show up "including renderD128" before adding the vfio options

Is it something to do with kernel driver not loading in the VM? Hope someone can help and please explain as if I'm a noob because I really am lol


EDIT:
If it helps this is what I currently get in Frigate when trying to use hardware acceleration currently:
frigate.util ERROR : Unable to poll radeon GPU stats: Failed to find DRM devices: error 2 (No such file or directory)

VAINFOR OUTPUT Return Code: 1 Process Error: error: XDG_RUNTIME_DIR is invalid or not set in the environment. error: can't connect to X server! error: failed to initialize display
 
Last edited:
Can anyone help? Really want to get to the bottom of this and get my system running as smoothly as possible...
 
I do not know with AMD HW. But you might be able to look at how we did it with intel HW and do something similar
https://forum.proxmox.com/threads/1...uenas-plex-hardware-transcoding-guide.125404/

Thank you for replying and trying to help but I've realised I made a huge mistake when posting initially, I'm not running Debian in a container its a VM, Doh!

That's why I am having trouble, seems everyone is able to get this to work in a container but not a VM?

Typically I switched from a container to a VM to get my coral to pass through as I couldn't get it to work on the container but wondering now if I might have to go back to a container and try both coral and gpu passthrough again into a container see if I have any joy...
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!