Question about USB pass-through

Astraea

Renowned Member
Aug 25, 2018
224
40
68
I have recently built myself a new desktop workstation that is running a 5950x on an Asus x570 Gaming-E Wi-Fi II motherboard with 128 GB of ram and 2 GPUs. I have a monitor and keyboard connected to the system using the monitor's built-in KVM (Gigabyte M27Q). Has anyone tried USB passthrough via Device when using a KVM to share USB devices between 2 VMs?

If I do the passthrough of the USB using a port there are no issues until I restart the system. When the system comes back online the ports to where each device is connected change and no longer match the VM configurations. When I try to pass them through using the device method it only ever works on the first VM that I start, I am guessing because the device is the same on both sides of the KVM the first VM does not release the device for the second when I switch it using the KVM.

Is there a way to make this work with the Device method or do I just have to live with having to adjust the ports when I need to reboot the machine, though with live USB hot-plugging this is much less of a pain than it used to be in previous PVE versions.
 
I have a similar setup and I PCIe passthrough one USB controller to one VM and another to another VM. Then switching using my simple USB KVM works fine and gives good performance.
USB passthrough, which does not work well for high-bandwidth or low-latancy, only works on devices and ports and unfortunately not on USB hubs.
However, I did notice that the port number-sequences were stable. If I connect the USB KVM twice to the Promox host, I see either one set of ports or another (depending on the switch on the KVM) and they are different sets. You could try passthrough of the different ports number-sequence sets to different VMs, instead of device identifications.
 
I am using Ports to pass them through right now and depending on which way I have the KVM switch the devices show on different ports. I am not able to pass through the USB controller using PCI-e as they are onboard USB ports and the IOMMU groups are stopping me from doing that. I did try connecting the devices to the addon USB cards that I have for each VM but had stability issues with the mouse and keyboard for some reason so I went back to using the onboard USB ports.
 

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!