Help with amdgpu Passthrough for LXC


New Member
Oct 23, 2023
Hello everybody.

I have a Ryzen 7 5700u mini pc and I'm trying to passthrough the gpu to an LXC with the frigate. Proxmox 8.0.9

I followed several tutorials, tried several different things, but there was always a point where I couldn't move forward.
Some files didn't exist in my installation and had to be created, I don't know to what extent this matters:

# This file contains a list of modules which are not supported by Proxmox VE

# nvidiafb see bugreport
blacklist nouveau
blacklist nvidia
blacklist nvidiafb
blacklist snd_hda_codec_hdmi
blacklist snd_hda_intel
blacklist snd_hda_codec
blacklist snd_hda_core
blacklist radeon
blacklist amdgpu

options vfio-pci ids=1002:164c,1002:1637
softdep radeon pre: vfio-pci
softdep amdgpu pre: vfio-pci
softdep snd_hda_intel pre: vfio-pci

/etc/modprobe.d/vfio-pci.conf is empty

# /etc/modules: kernel modules to load at boot time.
# This file contains the names of kernel modules that should be loaded
# at boot time, one per line. Lines beginning with "#" are ignored.
# Parameters can be specified after the module name.


root@pve:~#  find /sys/kernel/iommu_groups/ -type l

root@pve:~#  dmesg | grep -e DMAR -e IOMMU -e AMD-Vi
[    0.128404] AMD-Vi: ivrs, add hid:AMDI0020, uid:\_SB.FUR0, rdevid:160
[    0.128406] AMD-Vi: ivrs, add hid:AMDI0020, uid:\_SB.FUR1, rdevid:160
[    0.128407] AMD-Vi: ivrs, add hid:AMDI0020, uid:\_SB.FUR2, rdevid:160
[    0.128408] AMD-Vi: ivrs, add hid:AMDI0020, uid:\_SB.FUR3, rdevid:160
[    0.128409] AMD-Vi: Using global IVHD EFR:0x206d73ef22254ade, EFR2:0x0
[    0.402035] pci 0000:00:00.2: AMD-Vi: IOMMU performance counters supported
[    0.402893] pci 0000:00:00.2: AMD-Vi: Found IOMMU cap 0x40
[    0.402895] AMD-Vi: Extended features (0x206d73ef22254ade, 0x0): PPR X2APIC NX GT IA GA PC GA_vAPIC
[    0.402904] AMD-Vi: Interrupt remapping enabled
[    0.402906] AMD-Vi: X2APIC enabled
[    0.667845] AMD-Vi: Virtual APIC enabled
[    0.668540] perf/amd_iommu: Detected AMD IOMMU #0 (2 banks, 4 counters/bank).

root@pve:~# lspci -nn | grep -e 'AMD/ATI'
04:00.0 VGA compatible controller [0300]: Advanced Micro Devices, Inc. [AMD/ATI] Lucienne [1002:164c] (rev c1)
04:00.1 Audio device [0403]: Advanced Micro Devices, Inc. [AMD/ATI] Renoir Radeon High Definition Audio Controller [1002:1637]

# If you change this file, run 'update-grub' afterwards to update
# /boot/grub/grub.cfg.
# For full documentation of the options in this file, see:
#   info -f grub -n 'Simple configuration'

GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian`

# If your computer has multiple operating systems installed, then you
# probably want to run os-prober. However, if your computer is a host
# for guest OSes installed via LVM or raw disk devices, running
# os-prober can cause damage to those guest OSes as it mounts
# filesystems to look for things.

# Uncomment to enable BadRAM filtering, modify to suit your needs
# This works with Linux (no patch required) and with any kernel that obtains
# the memory map information from GRUB (GNU Mach, kernel of FreeBSD ...)

# Uncomment to disable graphical terminal

# The resolution used on graphical terminal
# note that you can use only modes which your graphic card supports via VBE
# you can see them in real GRUB with the command `vbeinfo'

# Uncomment if you don't want GRUB to pass "root=UUID=xxx" parameter to Linux

# Uncomment to disable generation of recovery mode menu entries

# Uncomment to get a beep at grub start
#GRUB_INIT_TUNE="480 440 1"

As far as I understand, everything is correct up to this point, right?
If so, my problem starts here:
root@pve:~# ls -l /dev/dri
ls: cannot access '/dev/dri': No such file or directory

What I need to do?

Last edited:
You want to:
passthrough the gpu to an LXC
but what you actually do with all the stuff you described is:
which is for VMs.
With the latter, one wants that the PVE-host does not use the specific device(s) at all; therefore the module-blacklisting and vfio-pci-binding, you did.
But for the former (what you want to do), the PVE-host absolutely needs full access of the specific device(s).
See the problem? ;)

Unfortunately, I have no experience with AMD GPUs/APUs and LXC-passthrough, sorry.
  • Like
Reactions: leesteken
Thanks for pointing out the stupid mistake, newbie here.
I was totally lost in the settings, thinking that part of the process for VM and LXC was the same.

As I was unable to revert the settings I made for the GPU, I did a new installation of Proxmox.

Now it's working.
  • Like
Reactions: Neobin


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!