Passthrough with vfio does not work : Debian freezes on boot

Getting your soundcard to work, using Debian on non-i386 hardware, etc

Re: Passthrough with vfio does not work : Debian freezes on

Postby marietto » 2019-10-06 09:14

I tried to generate the xorg.conf file with this command :

mario@DESKTOP-N9UN2H3:/home/mariozio# Xorg -configure

but it didn't work :

using config file : "/root/xorg.conf.new"
using system config directory "/usr/share/X11/xorg.conf.d"
modprobe: FATAL: module fbcon not found in directory /lib/modules/4.19.0-6-amd64
intel : waited 2020 ms for i915.ko driver to load
number of created screens does not match number of detected devices
configuration failed
marietto
 
Posts: 52
Joined: 2014-07-13 16:30

Re: Passthrough with vfio does not work : Debian freezes on

Postby marietto » 2019-10-06 09:54

maybe the solution is this :

https://unix.stackexchange.com/question ... umber-of-d

interesting what he says : This would restrict the X server to use only the Intel iGPU and ignore the Nvidia dGPU for now, and to auto-detect all the input devices, display resolutions etc.
marietto
 
Posts: 52
Joined: 2014-07-13 16:30

Re: Passthrough with vfio does not work : Debian freezes on

Postby CwF » 2019-10-06 13:33

marietto wrote:use only the Intel iGPU and ignore the Nvidia dGPU for now

Not for now, forever!

Back to that milestone list, your skipping #1. Rip out the damn nvidia card and get debian working first.
You do NOT want a xorg file anywhere!

You've taken a big bite here and are having trouble chewing!

...and at the end of the day the nvidia is a poor choice to pass to windows. The windows drivers may refuse to work leaving you with an error 43 or maybe 10, requiring more tricks to get it working. Quadro hardware and drivers will work well in a windows vm. The motherboard is not a great choice either, strike two.

Get the machine working on the intel only, otherwise strike three.

Sorry I couldn't help.
CwF
 
Posts: 499
Joined: 2018-06-20 15:16

Re: Passthrough with vfio does not work : Debian freezes on

Postby marietto » 2019-10-06 21:43

I'm trying to remove the nvidia driver and make work the intel driver,but I'm not able to do that.
marietto
 
Posts: 52
Joined: 2014-07-13 16:30

Re: Passthrough with vfio does not work : Debian freezes on

Postby marietto » 2019-10-08 09:00

I did make some progress. I've installed the kernel 5.2.0 with these commands :

# as root
echo 'deb http://ftp.de.debian.org/debian buster-backports main' | tee -a /etc/apt/sources.list
apt update
apt policy linux-image-amd64
apt install linux-image-amd64=5.2+106~bpo10+1

since it gave this error :

root@DESKTOP-N9UN2H3:/home/mariozio# apt install linux-headers-5.2.0-0.bpo.2-amd64
Configurazione di linux-headers-5.2.0-0.bpo.2-amd64 (5.2.9-2~bpo10+1)...
/etc/kernel/header_postinst.d/dkms:
Error! Bad return status for module build on kernel: 5.2.0-0.bpo.2-amd64 (x86_64)
Consult /var/lib/dkms/nvidia-current/418.74/build/make.log for more information.

I gave these commands :

sudo apt purge dkms

sudo apt autoremove

sudo apt autoclean

sudo apt install dkms

now it says : can't connect to Xorg when I'm on rescue mode. And it freezes when it says : "gnome desktop manager initialized" when I'm on the normale mode. Anyway this kernel is able to make work the intel graphic chipset embedded inside the mobo. Actually the monitor attached to the nvidia graphic card is turned off. The monitor attached to the intel graphic is turned on.
marietto
 
Posts: 52
Joined: 2014-07-13 16:30

Re: Passthrough with vfio does not work : Debian freezes on

Postby marietto » 2019-10-08 09:02

I gave these commands to fix the problem :

apt install firmware-linux-free libgles-nvidia1 libgles-nvidia2 libnvidia-cfg1 libopengl0 nvidia-persistenced nvidia-settings nvidia-vulkan-icd

but it freezes again on boot,giving the error "failed to start nvidia persistence demon" ; failed to load kernel modules....
marietto
 
Posts: 52
Joined: 2014-07-13 16:30

Re: Passthrough with vfio does not work : Debian freezes on

Postby CwF » 2019-10-08 12:38

This is the wrong thread for your progress. I see your intel gpu might need a newer kernel to get it working, I appreciate that, but if your goal is to vfio pass the nvidia I'm starting to wonder if you know what that means?

To pass with vfio requires NO drivers or firmware for the nvidia, or whatever your passing!

Further, am I to ponder that you are installing nvidia software while having the device ID registered to vfio, and then wondering why it freezes?
CwF
 
Posts: 499
Joined: 2018-06-20 15:16

Re: Passthrough with vfio does not work : Debian freezes on

Postby marietto » 2019-10-10 14:20

with the help of a great user found on this forum I've been able to make work the passthrough of the nvidia card. Now I have another problem : the monitor connected to the intel graphic chipset is turned off. it means that there is something wrong with the drivers. He suggests to install the mesa drivers. can u give a look at the thread ? thanks.

http://forums.debian.net/viewtopic.php?f=5&t=143903&start=15
marietto
 
Posts: 52
Joined: 2014-07-13 16:30

Re: Passthrough with vfio does not work : Debian freezes on

Postby CwF » 2019-10-10 15:25

marietto wrote:I've been able to make work the passthrough of the nvidia card.

You're mixing up terms here, as far as I can tell. vfio passthrough means a secondary OS is given control of the 'passed' video card via qemu/kvm, xen, vb, or other hypervisor, the booted OS. It appears you have the nvidia happily running on the booted OS while disabling the onboard intel. That is a 'bypass' perhaps, but not vfio pass.
CwF
 
Posts: 499
Joined: 2018-06-20 15:16

Re: Passthrough with vfio does not work : Debian freezes on

Postby marietto » 2019-10-11 15:47

This is the best result that I've been able to reach. Both the monitors are working. The first one is attached to the nvidia,the second one on intel. The nvidia card kernel driver is not passed to vfio,but the nvidia audio controller it is controlled by vfio. what's the problem here ?

root@ziomario-Z390-AORUS-PRO:/home/ziomario# dmesg | grep -i vfio

[ 1.762658] VFIO - User Level meta-driver version: 0.3
[ 10.592555] vfio_pci: add [10de:1e04[ffffffff:ffffffff]] class 0x000000/00000000
[ 10.609495] vfio_pci: add [10de:10f7[ffffffff:ffffffff]] class 0x000000/00000000

root@ziomario-Z390-AORUS-PRO:/home/ziomario# lspci -nnv

01:00.0 VGA compatible controller [0300]: NVIDIA Corporation TU102 [GeForce RTX 2080 Ti] [10de:1e04] (rev a1) (prog-if 00 [VGA controller])
Subsystem: ZOTAC International (MCO) Ltd. TU102 [GeForce RTX 2080 Ti] [19da:2503]
Flags: bus master, fast devsel, latency 0, IRQ 129
Memory at 64000000 (32-bit, non-prefetchable) [size=16M]
Memory at 50000000 (64-bit, prefetchable) [size=256M]
Memory at 62000000 (64-bit, prefetchable) [size=32M]
I/O ports at 3000 [size=128]
[virtual] 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: [258] L1 PM Substates
Capabilities: [128] Power Budgeting <?>
Capabilities: [420] Advanced Error Reporting
Capabilities: [600] Vendor Specific Information: ID=0001 Rev=1 Len=024 <?>
Capabilities: [900] #19
Capabilities: [bb0] #15
Kernel driver in use: nvidia
Kernel modules: nvidiafb, nouveau, nvidia_drm, nvidia

01:00.1 Audio device [0403]: NVIDIA Corporation TU102 High Definition Audio Controller [10de:10f7] (rev a1)
Subsystem: ZOTAC International (MCO) Ltd. TU102 High Definition Audio Controller [19da:2503]
Flags: bus master, fast devsel, latency 0, IRQ 10
Memory at 65080000 (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

00:02.0 Display controller [0380]: Intel Corporation Device [8086:3e98] (rev 02)
Subsystem: Gigabyte Technology Co., Ltd Device [1458:d000]
Flags: bus master, fast devsel, latency 0, IRQ 127
Memory at 66000000 (64-bit, non-prefetchable) [size=16M]
Memory at 40000000 (64-bit, prefetchable) [size=256M]
I/O ports at 4000 [size=64]
Capabilities: [40] Vendor Specific Information: Len=0c <?>
Capabilities: [70] Express Root Complex Integrated Endpoint, MSI 00
Capabilities: [ac] MSI: Enable+ Count=1/1 Maskable- 64bit-
Capabilities: [d0] Power Management version 2
Capabilities: [100] Process Address Space ID (PASID)
Capabilities: [200] Address Translation Service (ATS)
Capabilities: [300] Page Request Interface (PRI)
Kernel driver in use: i915
Kernel modules: i915
marietto
 
Posts: 52
Joined: 2014-07-13 16:30

Re: Passthrough with vfio does not work : Debian freezes on

Postby CwF » 2019-10-12 13:52

marietto wrote:controlled by vfio. what's the problem here ?

One of us doesn't understand what you're doing.

I should maybe ask, what are you using as a hypervisor and what guest OS?

If the answer is 'What?', then please remove the file /etc/modprobe.d/vfio.conf, and modules listed in /etc/initramfs-tools/modules, and ever other mod for vfio, regen and reboot.
CwF
 
Posts: 499
Joined: 2018-06-20 15:16

Previous

Return to Hardware

Who is online

Users browsing this forum: No registered users and 5 guests

fashionable