You are not logged in.

#1 2022-01-25 21:55:55

dreigon
Member
Registered: 2022-01-25
Posts: 4

virt-manager hanging after attempting to run GPU passthrough

Hi all. I have been attempting to passthrough my GPU to a VM (via this guide). I'm on a GTX 1080. What will happen is I try to start the VM, and virt-manager will become unresponsive for about a minute. After that minute, it returns this error:

Error starting domain: Cannot recv data: Connection reset by peer

Traceback (most recent call last):

File "/usr/share/virt-manager/virtManager/asyncjob.py", line 65, in cb_wrapper

callback(asyncjob, *args, **kwargs)

File "/usr/share/virt-manager/virtManager/asyncjob.py", line 101, in tmpcb

callback(*args, **kwargs)

File "/usr/share/virt-manager/virtManager/object/libvirtobject.py", line 57, in newfn

ret = fn(self, *args, **kwargs)

File "/usr/share/virt-manager/virtManager/object/domain.py", line 1329, in startup

self._backend.create()

File "/usr/lib/python3.9/site-packages/libvirt.py", line 1353, in create

raise libvirtError('virDomainCreate() failed')

libvirt.libvirtError: Cannot recv data: Connection reset by peer

All of the scripts in /etc/libvirt/hooks are executable and i checked they worked by running them by themselves, which they did. I haven't managed to find much about this issue online, so does anyone have a solution?

Offline

#2 2022-01-26 00:38:02

gabekings
Member
Registered: 2021-12-23
Posts: 5

Re: virt-manager hanging after attempting to run GPU passthrough

Dont know about this issue in particular BUT i highly recommend you the arch wiki guide. https://wiki.archlinux.org/title/PCI_pa … h_via_OVMF Tried last week and work flawlessly and im using the GTX1070. I used the cpu to maintain host and GPU for VM.

Offline

#3 2022-01-26 07:31:54

dreigon
Member
Registered: 2022-01-25
Posts: 4

Re: virt-manager hanging after attempting to run GPU passthrough

I don't have integrated graphics on my system, and i dont intend to use them.

Last edited by dreigon (2022-01-26 07:36:52)

Offline

#4 2022-01-26 11:30:31

Lone_Wolf
Administrator
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 15,261

Re: virt-manager hanging after attempting to run GPU passthrough

For clarity :

how many videocards does your system have ?
post lspci -k (run as user)


Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.

clean chroot building not flexible enough ?
Try clean chroot manager by graysky

Offline

#5 2022-01-26 14:29:23

dreigon
Member
Registered: 2022-01-25
Posts: 4

Re: virt-manager hanging after attempting to run GPU passthrough

1. I have a gtx 1080 using nvidia propietary driver, no other gpu, cannot lspci -k right now, I'm not at home, but I do know I have 1 GPU

Last edited by dreigon (2022-01-26 14:35:28)

Offline

#6 2022-01-27 09:32:39

Lone_Wolf
Administrator
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 15,261

Re: virt-manager hanging after attempting to run GPU passthrough

# Detach GPU devices from host
# Use your GPU and HDMI Audio PCI host device
virsh nodedev-detach pci_0000_01_00_0
virsh nodedev-detach pci_0000_01_00_1

The start and stop scripts mentioned in that guide are hardcoded for those specific addresses, do those match your hardware ?
(lspci would show that) .


Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.

clean chroot building not flexible enough ?
Try clean chroot manager by graysky

Offline

#7 2022-01-27 10:28:43

dreigon
Member
Registered: 2022-01-25
Posts: 4

Re: virt-manager hanging after attempting to run GPU passthrough

yeah they match, as I said, the scripts work by themselves and they do detach the gpu fine, the problem comes when I run it in virt manager

Offline

#8 2022-01-28 13:43:44

Lone_Wolf
Administrator
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 15,261

Re: virt-manager hanging after attempting to run GPU passthrough

Could be a permission / authentication issue, you have followed https://wiki.archlinux.org/title/Libvir … entication ?


Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.

clean chroot building not flexible enough ?
Try clean chroot manager by graysky

Offline

Board footer

Powered by FluxBB