virglrenderer for 3d support

you could try 'radeontop'
Thanks!

It installed, and is pulling statistics from my GPU, even if it doesn't know what it is. ... Which surprises me a bit. I might have to file a bug report.

Apparently, the GPU is configured to pull just 512 MB of system RAM. That's ... not ideal. I'm going to have to get into the BIOS to see if I can adjust that.
 
Thanks again for all your help.

I've had another question come up. I'd like to allocate more than 512M of VRAM to a VM using the VirGL driver ... but the GUI won't let me. It won't let me save my changes to the Display unless it's at 512 MiB or less.

1669946429719.png

I tried editing the VM's config file directly, though PVE might be getting confused because I'm using snapshots and it's inheriting from a snapshot that doesn't show that edit. I'll delete all the snapshots again this weekend--I won't need them after I finish some updates and nothing breaks.

In the meantime, shouldn't the GUI let me assign more than 512 MiB of VRAM to a VirGL-enabled VM? I would think that would be necessary for a VM doing actual gaming.

Also, is there a command I can run inside the VM to see how much VRAM it thinks it has?
 
This has my interest although its a shame about the bloat package.

VMs are pretty performant in proxmox, but as soon as I try to play media inside a windows VM, it needs really high CPU usage and drops frames etc. I assume this is due to a lack of offloading hence my interest.
 
VMs are pretty performant in proxmox, but as soon as I try to play media inside a windows VM, it needs really high CPU usage and drops frames etc. I assume this is due to a lack of offloading hence my interest.
Watching 720p60 youtube on a Linux VM can indeed use almost 4 vCPU (with SPICE 128MB on Linux) but looks fine. I tried VirGL (512MB with 4GB GPU) and it works with much less CPU but I see a lot of tearing, which makes it unwatchable. VirGL was really easy to use with Proxmox and does work well for WebGL and such.
 
  • Like
Reactions: chrcoluk
I discovered that virtio gpu used by proxmox is actually virtio-vga (the two are different, so they perhaps should fix the naming to avoid confusion) I then changed it to virtio-vga-gl which is supported in qemu using custom args flags, but got a no opengl support error, and since I am busy had to stop there, but might come back to this.
 
I discovered that virtio gpu used by proxmox is actually virtio-vga (the two are different, so they perhaps should fix the naming to avoid confusion) I then changed it to virtio-vga-gl which is supported in qemu using custom args flags, but got a no opengl support error, and since I am busy had to stop there, but might come back to this.
I just selected VirGL GPU in the Proxmox GUI, and installed the two required libraries on the Proxmox host.
 
I just selected VirGL GPU in the Proxmox GUI, and installed the two required libraries on the Proxmox host.
Yeah I avoided doing that for now due to the dependency bloat, but since it seems to be the only GL option in Proxmox I will probably do the same when I have further time to test. Your feedback is good as it shows its probably worth it with the improvements you have, one issue though is there seems to be no windows driver for VirGL?
 
I discovered that virtio gpu used by proxmox is actually virtio-vga (the two are different, so they perhaps should fix the naming to avoid confusion) I then changed it to virtio-vga-gl
Yes, VGA == GPU, so VirtioGPU is virtio-vga and VirGL virtio-vga-gl, not really confusing; especially if you stick to the CLI/API or even Web UI.
but got a no opengl support error,
Well, assembling the GPU part manually we args can't do magic, you still need actual OpenGL support on the Proxmox VE host system, i.e., the two libraries recommended in the docs.
one issue though is there seems to be no windows driver for VirGL?
No, there aren't any, it's a huge PITA to add support for such things in Windows, as everything there is pretty closed & fully proprietary and Microsoft can't be bothered to do anything to really help Open Source, at least if it isn't benefitting directly them more than others. But I digress – anyhow, IIRC, some poor GSoC student tried their luck but got stuck. That might maybe change with mesa's more modern Virtio-GPU Venus project, that is very similar to VirGL but passes through Vulkan, not OpenGL, commands/protocol it could have a higher chance to also work for Windows thanks to the work of the Open Source community, e.g., with the DXVK project (Direct3D to Vulkan translation).
 
Well Nvidia seem to have released something to allow it to work over RDP for geforce cards, but its not clear if its the host or the machine running the RDP client that needs the Nvidia GPU, if its the latter it could be perfect.
 
That might maybe change with mesa's more modern Virtio-GPU Venus project, that is very similar to VirGL but passes through Vulkan, not OpenGL, commands/protocol it could have a higher chance to also work for Windows thanks to the work of the Open Source community, e.g., with the DXVK project (Direct3D to Vulkan translation).
Ok, wirglrenderer 1.0.0. is out now.
https://gitlab.freedesktop.org/virgl/virglrenderer/-/releases/1.0.0

And switch to Venus protocol version 1.0.0

Is this what you mean?

Can you please support it in Proxmox.?

Thanks
 
Is this what you mean?
Basically.
Can you please support it in Proxmox.?
We'll look into this, but newer QEMU and also supporting graphical library packages might be required, so I'd not hold my breath for a very quick update to this. In the worst case, it might not be realistic to upgrade those without wide breakage in the ecosystem, so it might then even need a new Debian release cycle (due mid 2025). I'm not expecting that just yet, but I want to manage expectations here.
 
  • Like
Reactions: Tmanok
Virtio-GPU Venus would be a big leap! The current Virtio-GPU is not Venus right? It needs a special QEMU build right?
 
Last edited:
Virtio-GPU Venus would be a big leap! The current Virtio-GPU is not Venus right? It needs a special QEMU build right?
That's my understanding.

Venus is meant to completely replace Virtio-GPU (or, more specifically, VirGL), as far as its devs are concerned. I'm not sure if that means VirGL is no longer under active development or not.
 
My understanding is that virglrenderer now supports Venus as well as OpenGL via the VirtIO-GPU.
https://www.collabora.com/news-and-...s-on-qemu-enabling-new-virtual-vulkan-driver/
I do undertand it the same way. Still you need qemu, libgl, virgl and mesa packages with recent versions to support it.

I tried to use virgl-vaapi with recent Debian Testing release on the proxmox host as well as current Ubuntu 23.10 on the guest but I did not succeed. I'd need Vulkan for Gaming on a VM and virgl-vaapi to encode video streams to access this VM.
 
I tried something similar a few weeks ago and was also unsuccessful. I have just come across the following:
https://gist.github.com/mildsunrise/ad48bc19c30b36197b57756b7fd98bba

Video: virglrenderer can also expose accelerated video decoding / encoding through VA-API. This isn't a separate virtio-gpu capability set, instead it's carried as an optional part of VirGL (support for it is advertised inside the VIRGL capability blob, see below). This is currently an unstable API.
Pass

-Dvideo=enabled
when building, and flag

VIRGL_RENDERER_USE_VIDEO
See this comment for more info about the general architecture.
 
Last edited:
I tried something similar a few weeks ago and was also unsuccessful. I have just come across the following:
https://gist.github.com/mildsunrise/ad48bc19c30b36197b57756b7fd98bba
Thanks for bringing this up! I guess for us as end users this is nothing we could take care of, but @SInisterPisces could maybe use this information for the PVE folks to implement the feature.

I'm not sure if this is still needed with the stable VirGL renderer release. I assume with current builds of VirGL, qemu, virtio, mesa et. al. this should not be needed anymore but I'm not sure.
 
Possibly dumb question ahead...

Can VirGL be used to output the VM's video directly to a monitor through HDMI? Or is that only with hardware passthrough?
 
Possibly dumb question ahead...

Can VirGL be used to output the VM's video directly to a monitor through HDMI? Or is that only with hardware passthrough?
not possible, you need full igpu passthrough to have video on screen. this can be doable at least i am using it now on Alderlake with Intel i5-12400.
 
  • Like
Reactions: ecotechie

About

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!