mirror of
https://github.com/containers/podman.git
synced 2025-06-19 16:33:24 +08:00
Merge pull request #20540 from victortoso/usb-host-passthrough
qemu: add usb host passthrough
This commit is contained in:
@ -104,6 +104,20 @@ means to use the timezone of the machine host.
|
||||
The timezone setting is not used with WSL. WSL automatically sets the timezone to the same
|
||||
as the host Windows operating system.
|
||||
|
||||
#### **--usb**=*bus=number,devnum=number* or *vendor=hexadecimal,product=hexadecimal*
|
||||
|
||||
Assign a USB device from the host to the VM via USB passthrough.
|
||||
Only supported for QEMU Machines.
|
||||
|
||||
The device needs to have proper permissions in order to be passed to the machine. This
|
||||
means the device needs to be under your user group.
|
||||
|
||||
Note that using bus and device number are simpler but the values can change every boot
|
||||
or when the device is unplugged.
|
||||
|
||||
When specifying a USB using vendor and product ID's, if more than one device has the
|
||||
same vendor and product ID, the first available device is assigned.
|
||||
|
||||
@@option user-mode-networking
|
||||
|
||||
#### **--username**
|
||||
@ -160,6 +174,8 @@ $ podman machine init --rootful
|
||||
$ podman machine init --disk-size 50
|
||||
$ podman machine init --memory=1024 myvm
|
||||
$ podman machine init -v /Users:/mnt/Users
|
||||
$ podman machine init --usb vendor=13d3,product=5406
|
||||
$ podman machine init --usb bus=1,devnum=3
|
||||
```
|
||||
|
||||
## SEE ALSO
|
||||
|
@ -52,6 +52,20 @@ are no longer visible with the default connection/socket. This is because the ro
|
||||
users in the VM are completely separated and do not share any storage. The data however is not
|
||||
lost and you can always change this option back or use the other connection to access it.
|
||||
|
||||
#### **--usb**=*bus=number,devnum=number* or *vendor=hexadecimal,product=hexadecimal* or *""*
|
||||
|
||||
Assign a USB device from the host to the VM.
|
||||
Only supported for QEMU Machines.
|
||||
|
||||
The device needs to be present when the VM starts.
|
||||
The device needs to have proper permissions in order to be assign to podman machine.
|
||||
|
||||
Use an empty string to remove all previously set USB devices.
|
||||
|
||||
Note that using bus and device number are simpler but the values can change every boot or when the
|
||||
device is unplugged. Using vendor and product might lead to collision in the case of multiple
|
||||
devices with the same vendor product value, the first available device is assigned.
|
||||
|
||||
@@option user-mode-networking
|
||||
|
||||
## EXAMPLES
|
||||
|
Reference in New Issue
Block a user