Is there a gui option for adding a usb device to a running VM?

Hi,

While you can add USB devices via the Webinterface directly it is not yet possible to hotplug them.
It's a sensible request which bothered me too in the past, the underlying issue for why it currently didn't get done is live migration.

Naturally that's not possible with a USB passthrough, but if one allows hot plug and unplug a user could plug an USB then unplug for live-migration, but due to the plug/unplug they triggered the internal machine layout got and USB hub and which the migration cannot know about.

The current idea to solve this is to allow adding USB Hubs manually, those are then also in the configuration and live migration works again (once all USB devices got unplugged from the VM).

Could you please open an enhancement request for this over at https://bugzilla.proxmox.com/ so we can track it? That'd be great!
 
  • Like
Reactions: flames
The documentation on adding USB 3 devices to a running VM leaves a hell of a lot to be desired. Reminds me of the "draw the rest of the owl" meme.

"USB3.0
qm monitor 804

device_add nec-usb-xhci,id=xhci,addr=0x1B,bus=pci.1
device_add usb-host,bus=xhci.0,vendorid=0x0480,productid=0xa007,id=anotherid

anotherid is chosen by you, so the device can later be removed again"
 
Last edited:
The documentation on adding USB 3 devices to a running VM leaves a hell of a lot to be desired. Reminds me of the "draw the rest of the owl" meme.

"USB3.0
qm monitor 804

device_add nec-usb-xhci,id=xhci,addr=0x1B,bus=pci.1
device_add usb-host,bus=xhci.0,vendorid=0x0480,productid=0xa007,id=anotherid

anotherid is chosen by you, so the device can later be removed again"
Do you mind explaining what the parameters are? I tried the commands but it didn't work
 
Is there anything planned to allow USB hotplug? We use this quite a bit for attaching license dongles to VMs, and having to reboot the VM for a USB unplug/plug change feels like 1995.

And if this hinders live-migration this is totally understandable for me. We have quite some VMs with PCIe passthrough, which have the same issue. PCIe hotplug is probably a completely different beast. But not having simple USB hotplug while the VM stays on the host where the USB stick is, is really a pain...
 
Last edited:
usb hotplug is implemented since quite a while..
if it does not work for you, can you post your vm config (qm config ID) and versions (pveversion -v) ?