You are not logged in.

#1 2024-09-16 08:55:07

burny02
Member
Registered: 2021-07-01
Posts: 115

Virgl Virtio - Vulkan

Hi

I am attempting to get Vulkan working on my accellerated VM. I get the following error

vulkaninfo --summary
WARNING: [Loader Message] Code 0 : terminator_CreateInstance: Received return code -3 from call to vkCreateInstance in ICD /usr/lib/libvulkan_virtio.so. Skipping this driver.
ERROR: [Loader Message] Code 0 : terminator_CreateInstance: Found no drivers!
Cannot create Vulkan instance.
This problem is often caused by a faulty installation of the Vulkan driver or attempting to use a GPU that does not support Vulkan.
ERROR at /usr/src/debug/vulkan-tools/Vulkan-Tools-1.3.269/vulkaninfo/./vulkaninfo.h:688:vkCreateInstance failed with ERROR_INCOMPATIBLE_DRIVER

Can anyone help ? Am I missing a package or something?


I bit of background; I have a VM I use to let my kids stream games - This allows me to continue using my machine.

Recently it seems sunshine/drivers/virtualization has made this possible. Previously it would not be accelerated and max out the CPU.
This is really great; it means I do not have to pass through a GPU. It is working flawlessly with presumably openGL. I only noticed Vulkan didn't seem to be working when adding a game to Lutris; I got the message 'Error Vulkan is not installed or is not supported by your system. DXVK is not available'

Thanks in advance

Offline

#2 2024-09-16 13:19:54

Lone_Wolf
Administrator
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 13,279

Re: Virgl Virtio - Vulkan

Please post the outputs from the guest of these commands

$ lspci -k
$ pacman -Qs vulkan

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

#3 2024-09-16 14:12:30

burny02
Member
Registered: 2021-07-01
Posts: 115

Re: Virgl Virtio - Vulkan

lspci -k

00:00.0 Host bridge: Intel Corporation 82G33/G31/P35/P31 Express DRAM Controller
	Subsystem: Red Hat, Inc. QEMU Virtual Machine
	Kernel modules: intel_agp
00:01.0 PCI bridge: Red Hat, Inc. QEMU PCIe Root port
	Subsystem: Red Hat, Inc. Device 0000
	Kernel driver in use: pcieport
00:01.1 PCI bridge: Red Hat, Inc. QEMU PCIe Root port
	Subsystem: Red Hat, Inc. Device 0000
	Kernel driver in use: pcieport
00:01.2 PCI bridge: Red Hat, Inc. QEMU PCIe Root port
	Subsystem: Red Hat, Inc. Device 0000
	Kernel driver in use: pcieport
00:01.3 PCI bridge: Red Hat, Inc. QEMU PCIe Root port
	Subsystem: Red Hat, Inc. Device 0000
	Kernel driver in use: pcieport
00:01.4 PCI bridge: Red Hat, Inc. QEMU PCIe Root port
	Subsystem: Red Hat, Inc. Device 0000
	Kernel driver in use: pcieport
00:01.5 PCI bridge: Red Hat, Inc. QEMU PCIe Root port
	Subsystem: Red Hat, Inc. Device 0000
	Kernel driver in use: pcieport
00:01.6 PCI bridge: Red Hat, Inc. QEMU PCIe Root port
	Subsystem: Red Hat, Inc. Device 0000
	Kernel driver in use: pcieport
00:01.7 PCI bridge: Red Hat, Inc. QEMU PCIe Root port
	Subsystem: Red Hat, Inc. Device 0000
	Kernel driver in use: pcieport
00:02.0 PCI bridge: Red Hat, Inc. QEMU PCIe Root port
	Subsystem: Red Hat, Inc. Device 0000
	Kernel driver in use: pcieport
00:05.0 Communication controller: Red Hat, Inc. Virtio console
	Subsystem: Red Hat, Inc. Device 0003
	Kernel driver in use: virtio-pci
	Kernel modules: virtio_pci
00:07.0 Unclassified device [00ff]: Red Hat, Inc. Virtio memory balloon
	Subsystem: Red Hat, Inc. Device 0005
	Kernel driver in use: virtio-pci
	Kernel modules: virtio_pci
00:1f.0 ISA bridge: Intel Corporation 82801IB (ICH9) LPC Interface Controller (rev 02)
	Subsystem: Red Hat, Inc. QEMU Virtual Machine
	Kernel driver in use: lpc_ich
	Kernel modules: lpc_ich
00:1f.2 SATA controller: Intel Corporation 82801IR/IO/IH (ICH9R/DO/DH) 6 port SATA Controller [AHCI mode] (rev 02)
	Subsystem: Red Hat, Inc. QEMU Virtual Machine
	Kernel driver in use: ahci
00:1f.3 SMBus: Intel Corporation 82801I (ICH9 Family) SMBus Controller (rev 02)
	Subsystem: Red Hat, Inc. QEMU Virtual Machine
	Kernel driver in use: i801_smbus
	Kernel modules: i2c_i801
01:00.0 PCI bridge: Red Hat, Inc. Device 000e
03:00.0 Ethernet controller: Red Hat, Inc. Virtio 1.0 network device (rev 01)
	Subsystem: Red Hat, Inc. Device 1100
	Kernel driver in use: virtio-pci
	Kernel modules: virtio_pci
04:00.0 VGA compatible controller: Red Hat, Inc. Virtio 1.0 GPU (rev 01)
	Subsystem: Red Hat, Inc. Device 1100
	Kernel driver in use: virtio-pci
	Kernel modules: virtio_pci
05:00.0 USB controller: Red Hat, Inc. QEMU XHCI Host Controller (rev 01)
	Subsystem: Red Hat, Inc. Device 1100
	Kernel driver in use: xhci_hcd
	Kernel modules: xhci_pci
06:00.0 SCSI storage controller: Red Hat, Inc. Virtio 1.0 block device (rev 01)
	Subsystem: Red Hat, Inc. Device 1100
	Kernel driver in use: virtio-pci
	Kernel modules: virtio_pci
07:00.0 SCSI storage controller: Red Hat, Inc. Virtio 1.0 SCSI (rev 01)
	Subsystem: Red Hat, Inc. Device 1100
	Kernel driver in use: virtio-pci
	Kernel modules: virtio_pci
09:00.0 SCSI storage controller: Red Hat, Inc. Virtio 1.0 block device (rev 01)
	Subsystem: Red Hat, Inc. Device 1100
	Kernel driver in use: virtio-pci
	Kernel modules: virtio_pci

pacman -Qs vulkan

local/gpu-viewer 3.04-1
    A frontend to glxinfo and vulkaninfo.
local/lib32-vulkan-icd-loader 1.3.295-1
    Vulkan Installable Client Driver (ICD) Loader (32-bit)
local/lib32-vulkan-virtio 1:24.2.2-1
    Open-source Vulkan driver for Virtio-GPU (Venus) - 32-bit
local/spirv-tools 2024.2-1 (vulkan-devel)
    API and commands for processing SPIR-V modules
local/vulkan-headers 1:1.3.295-1 (vulkan-devel)
    Vulkan header files
local/vulkan-icd-loader 1.3.295-1
    Vulkan Installable Client Driver (ICD) Loader
local/vulkan-mesa-layers 1:24.2.2-1
    Mesa's Vulkan layers
local/vulkan-tools 1.3.269-1 (vulkan-devel)
    Vulkan Utilities and Tools
local/vulkan-virtio 1:24.2.2-1
    Open-source Vulkan driver for Virtio-GPU (Venus)

Offline

#4 2024-09-16 14:20:09

cryptearth
Member
Registered: 2024-02-03
Posts: 1,243

Re: Virgl Virtio - Vulkan

Offline

#5 2024-09-16 15:16:21

burny02
Member
Registered: 2021-07-01
Posts: 115

Re: Virgl Virtio - Vulkan

cryptearth wrote:

Unfortunately not

Offline

#6 2024-09-16 15:37:51

cryptearth
Member
Registered: 2024-02-03
Posts: 1,243

Re: Virgl Virtio - Vulkan

Dang - but that topic sounds interesting. I tried the 3D acceleration myself a few times both with windows and linux but never got it to work properly without passthru of a physical second gpu.
Would be cool to leverage the power of the host gpu - even if it's just for linux guests.

Offline

#7 2024-09-16 15:40:53

burny02
Member
Registered: 2021-07-01
Posts: 115

Re: Virgl Virtio - Vulkan

I'm not sure if it's Sunshine leveraging virtio, that has changed (I'm pretty sure I raised an issue, somewhere). I'm not entirely sure it was just this though; I do remember lagging + high CPU even without moonlight

It works well though, Linux only, presumably opengl

Last edited by burny02 (2024-09-16 15:44:00)

Offline

#8 2024-09-16 19:10:25

cryptearth
Member
Registered: 2024-02-03
Posts: 1,243

Re: Virgl Virtio - Vulkan

Well - I get it working for OpenGL no problem - but Vulkan doesn't want to work.
From what I found there's some build from source to compile in the vulkan support ...

Offline

#9 2024-09-17 09:32:17

burny02
Member
Registered: 2021-07-01
Posts: 115

Re: Virgl Virtio - Vulkan

Maybe someone else can help?

I did wonder if this was viable for local playing, also - This is nice because it means you keep Steam in it's own VM, done.

It certainly works and is playable with Sunshine/Moonlight - But this adds a large overhead, so it's not like bare metal. Are there any other options ? Looking glass?

Offline

#10 2024-09-17 10:28:48

Lone_Wolf
Administrator
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 13,279

Re: Virgl Virtio - Vulkan

Looking glass requires using vfio passthrough and only works in windows guests.


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

#11 2024-09-17 13:15:57

burny02
Member
Registered: 2021-07-01
Posts: 115

Re: Virgl Virtio - Vulkan

Any other low latency methods ?

Offline

#12 2024-09-18 05:56:18

Toolybird
Member
Registered: 2017-09-30
Posts: 76

Re: Virgl Virtio - Vulkan

IIUC, I think you are looking for the "venus" Virtio-GPU driver [1]. AFAICT, this is still not ready. There are numerous components that all need to be in place before it will work. The latest status update info is here [2]. Essentially:

- virglrender (ready)
- mesa (ready)
- QEMU (NOT ready)
- kernel (NOT ready)

[1] https://docs.mesa3d.org/drivers/venus.html
[2] https://lists.gnu.org/archive/html/qemu … 03288.html

Offline

#13 2024-09-18 10:57:32

burny02
Member
Registered: 2021-07-01
Posts: 115

Re: Virgl Virtio - Vulkan

Thanks; this is really helpful! To be honest it's not much of an issue (personally) for me at the moment, as openGL is good

If anyone has an alternative from spice/rdp/moonlight for gaming (locally) that would be great.

The workaround for me is to have Steam installed on two machines and pointing to the same game directories. This is fine, I'd rather have it once, though!

Offline

#14 2024-12-11 18:25:36

peppergray
Member
Registered: 2024-12-11
Posts: 1

Re: Virgl Virtio - Vulkan

This is ready now!
- QEMU: https://www.phoronix.com/news/QEMU-9.2-Released
- kernel: https://www.phoronix.com/news/Linux-6.13-KVM

--
Edit:
I did a write-up here: https://gist.github.com/peppergrayxyz/f … -virtio-md

Last edited by peppergray (2024-12-11 18:27:09)

Offline

#15 2024-12-11 18:47:56

cryptearth
Member
Registered: 2024-02-03
Posts: 1,243

Re: Virgl Virtio - Vulkan

hooray
looking forward to kvm 2025
will be interesting how this will change the requirement for gpu passthru
also: is this still limited to linux guests or is there support for windows guests up on the horizon?

Offline

#16 2024-12-12 09:00:23

Lone_Wolf
Administrator
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 13,279

Re: Virgl Virtio - Vulkan

A windows driver is unlikely.

Both VirGL and Venus are part of mesa.

Microsoft does contribute to mesa but the vast majority of their contributions target WSL and focus on making usage of windows subsystems (DirectX et co) easier when running WSL .


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