solitarius
Cadet
- Joined
- Jun 17, 2022
- Messages
- 9
Hello,
I am trying to figure out how to use a GTX 1050 Ti in my Debian VM (to use it for transcoding in a linuxserver/plex docker.
Here is my config:
At this point, I do not know what I missed. I have notices that the lspci on the VM do not list as much capabilities for the GPU as it does in the TrueNAS host but I have not found out if it is relevant.
Any idea is much appreciated. Thanks in advance.
I am trying to figure out how to use a GTX 1050 Ti in my Debian VM (to use it for transcoding in a linuxserver/plex docker.
Here is my config:
- Motherboard: AsRock X570 Pro4
- CPU: AMD Ryzen 7 5700X (AM4, 3.40 GHz, 8 -Core)
- Memory: (x2) Kingston DDR4-2666MHz Single Rank ECC Unbuffered Module (1 x 32GB, DDR4-2666, DIMM 288 pin) Ref: KTH-PL426E/32G
- Graphic Card (for plex transcoding): Gigabyte GeForce GTX 1050 Ti D5 (4 GB)
- Graphic Card (for TrueNAS): Zotac GT710
- TrueNAS Scale: v22.02.2
- Debian VM: v11
- Enabled IOMMU on the mother board
- Isolated the GPU GTX 1050Ti : It seems to have correctly black listed the driver for this device and attributed it to vfio-pci.
Code:
root@truenas[~]# cat /etc/modprobe.d/nvidia.conf softdep nouveau pre: vfio-pci softdep nvidia pre: vfio-pci softdep nvidia* pre: vfio-pci
Code:
root@truenas[~]# cat /etc/modprobe.d/vfio.confoptions vfio-pci ids=10DE:1C82,10DE:0FB9
Code:
root@truenas[~]# cat /etc/modprobe.d/nvidia-blacklists-nouveau.conf # You need to run "update-initramfs -u" after editing this file. # see #580894 blacklist nouveau
Code:
root@truenas[~]# cat /etc/modprobe.d/nvidia-kernel-common.confalias char-major-195* nvidia #options nvidia NVreg_DeviceFileUID=0 NVreg_DeviceFileGID=44 NVreg_DeviceFileMode=0660 # To enable FastWrites and Sidebus addressing, uncomment these lines # options nvidia NVreg_EnableAGPSBA=1 # options nvidia NVreg_EnableAGPFW=1
Code:
root@truenas[~]# lspci -v 0a:00.0 VGA compatible controller: NVIDIA Corporation GP107 [GeForce GTX 1050 Ti] (rev a1) (prog-if 00 [VGA controller]) Subsystem: Gigabyte Technology Co., Ltd GP107 [GeForce GTX 1050 Ti] Flags: bus master, fast devsel, latency 0, IRQ 124, IOMMU group 25 Memory at fb000000 (32-bit, non-prefetchable) [size=16M] Memory at c0000000 (64-bit, prefetchable) [size=256M] Memory at d0000000 (64-bit, prefetchable) [size=32M] I/O ports at f000 [size=128 ] Expansion ROM at 000c0000 [disabled] [size=128K] Capabilities: [60] Power Management version 3 Capabilities: [68] MSI: Enable- Count=1/1 Maskable- 64bit+ Capabilities: [78] Express Legacy Endpoint, MSI 00 Capabilities: [100] Virtual Channel Capabilities: [250] Latency Tolerance Reporting Capabilities: [128] Power Budgeting <?> Capabilities: [420] Advanced Error Reporting Capabilities: [600] Vendor Specific Information: ID=0001 Rev=1 Len=024 <?> Capabilities: [900] Secondary PCI Express Kernel driver in use: vfio-pci Kernel modules: nouveau, nvidia_current_drm, nvidia_current 0a:00.1 Audio device: NVIDIA Corporation GP107GL High Definition Audio Controller (rev a1) Subsystem: Gigabyte Technology Co., Ltd GP107GL High Definition Audio Controller Flags: bus master, fast devsel, latency 0, IRQ 125, IOMMU group 25 Memory at fc080000 (32-bit, non-prefetchable) [size=16K] Capabilities: [60] Power Management version 3 Capabilities: [68] MSI: Enable- Count=1/1 Maskable- 64bit+ Capabilities: [78] Express Endpoint, MSI 00 Capabilities: [100] Advanced Error Reporting Kernel driver in use: vfio-pci Kernel modules: snd_hda_intel
- Checked nvidia-smi: I only have the GT710 card detected.
Code:
root@truenas[~]# nvidia-smi Fri Jul 29 17:46:53 2022 +-----------------------------------------------------------------------------+ | NVIDIA-SMI 460.91.03 Driver Version: 460.91.03 CUDA Version: 11.2 | |-------------------------------+----------------------+----------------------+ | GPU Name Persistence-M| Bus-Id Disp.A | Volatile Uncorr. ECC | | Fan Temp Perf Pwr:Usage/Cap| Memory-Usage | GPU-Util Compute M. | | | | MIG M. | |===============================+======================+======================| | 0 GeForce GT 710 Off | 00000000:04:00.0 N/A | N/A | | 40% 51C P8 N/A / N/A | 0MiB / 981MiB | N/A Default | | | | N/A | +-------------------------------+----------------------+----------------------+ +-----------------------------------------------------------------------------+ | Processes: | | GPU GI CI PID Type Process name GPU Memory | | ID ID Usage | |=============================================================================| | No running processes found | +-----------------------------------------------------------------------------+
- Installed the nvidia drivers using
apt install nvidia-driver firmware-misc-nonfree[I]
[/I] - Added the device to the VM: The device is listed:
Code:
root@vm:/home/vm# ls -alh /dev/dri/ total 0 drwxr-xr-x 3 root root 120 Jul 29 2022 . drwxr-xr-x 20 root root 3.2K Jul 29 15:52 .. drwxr-xr-x 2 root root 100 Jul 29 2022 by-path crw-rw---- 1 root video 226, 0 Jul 29 2022 card0 crw-rw---- 1 root video 226, 1 Jul 29 2022 card1 crw-rw---- 1 root render 226, 128 Jul 29 2022 renderD128 root@vm:/home/vm# ls -alh /dev/dri/by-path/ ^[[3~total 0 drwxr-xr-x 2 root root 100 Jul 29 2022 . drwxr-xr-x 3 root root 120 Jul 29 2022 .. lrwxrwxrwx 1 root root 8 Jul 29 2022 pci-0000:00:02.0-card -> ../card0 lrwxrwxrwx 1 root root 8 Jul 29 2022 pci-0000:00:07.0-card -> ../card1 lrwxrwxrwx 1 root root 13 Jul 29 2022 pci-0000:00:07.0-render -> ../renderD128
Code:
user@vm[~]# sudo lspci -v 00:07.0 VGA compatible controller: NVIDIA Corporation GP107 [GeForce GTX 1050 Ti] (rev a1) (prog-if 00 [VGA controller]) Subsystem: Gigabyte Technology Co., Ltd GP107 [GeForce GTX 1050 Ti] Physical Slot: 7 Flags: bus master, fast devsel, latency 0, IRQ 11 Memory at c8000000 (32-bit, non-prefetchable) [size=16M] Memory at 800000000 (64-bit, prefetchable) [size=256M] Memory at 810000000 (64-bit, prefetchable) [size=32M] I/O ports at c000 [size=128 ] Expansion ROM at c9060000 [virtual] [disabled] [size=128K] Capabilities: [60] Power Management version 3 Capabilities: [68] MSI: Enable- Count=1/1 Maskable- 64bit+ Capabilities: [78] Express Legacy Endpoint, MSI 00 Kernel driver in use: nvidia Kernel modules: nvidia 00:08.0 Audio device: NVIDIA Corporation GP107GL High Definition Audio Controller (rev a1) Subsystem: Gigabyte Technology Co., Ltd GP107GL High Definition Audio Controller Physical Slot: 8 Flags: bus master, fast devsel, latency 0, IRQ 11 Memory at c9040000 (32-bit, non-prefetchable) [size=16K] Capabilities: [60] Power Management version 3 Capabilities: [68] MSI: Enable- Count=1/1 Maskable- 64bit+ Capabilities: [78] Express Endpoint, MSI 00 Kernel driver in use: snd_hda_intel Kernel modules: snd_hda_intel
- Checked nvidia-smi: This is where I am stuck
Code:
root@vm:/home/vm# nvidia-smi No devices were found
At this point, I do not know what I missed. I have notices that the lspci on the VM do not list as much capabilities for the GPU as it does in the TrueNAS host but I have not found out if it is relevant.
Any idea is much appreciated. Thanks in advance.
Last edited: