qvm-device.rst 3.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116
  1. .. program:: qvm-device
  2. =============================================
  3. :program:`qvm-device` -- List/set VM devices
  4. =============================================
  5. Synopsis
  6. ========
  7. | :command:`qvm-device` [*options*] *DEVICE_CLASS* {list,ls,l} <*vm-name*>
  8. | :command:`qvm-device` [*options*] *DEVICE_CLASS* {attach,at,a} <*vm-name*> <*device*>
  9. | :command:`qvm-device` [*options*] *DEVICE_CLASS* {detach,dt,d} <*vm-name*> <*device*>
  10. | :command:`qvm-*DEVICE_CLASS*` [*options*] {list,ls,l,attach,at,a,detach,dt,d} <*vmname*> ...
  11. Tool can be called either as `qvm-device *DEVICE_CLASS* ...`, or
  12. `qvm-*DEVICE_CLASS* ...`. The latter is used for `qvm-pci`, `qvm-block` etc.
  13. Options
  14. =======
  15. .. option:: --help, -h
  16. Show this help message and exit
  17. .. option:: --verbose, -v
  18. increase verbosity
  19. .. option:: --quiet, -q
  20. decrease verbosity
  21. Commands
  22. ========
  23. list
  24. ^^^^
  25. | :command:`qvm-device` *DEVICE_CLASS* list [-h] [--verbose] [--quiet] [*VMNAME* [*VMNAME* ...]]
  26. List devices.
  27. .. option:: --all
  28. List devices from all qubes. You can use :option:`--exclude` to limit the
  29. qubes set.
  30. .. option:: --exclude
  31. Exclude the qube from :option:`--all`.
  32. aliases: ls, l
  33. attach
  34. ^^^^^^
  35. | :command:`qvm-device` *DEVICE_CLASS* attach [-h] [--verbose] [--quiet] [--ro] *VMNAME* *BACKEND_DOMAIN:DEVICE_ID*
  36. Attach the device with *DEVICE_ID* from *BACKEND_DOMAIN* to the domain *VMNAME*
  37. .. option:: --option, -o
  38. Specify device-class specific option, use `name=value` format. You can
  39. specify this option multiple times. See below for options specific to
  40. different device classes.
  41. .. option:: --ro
  42. Alias for the `read-only=yes` option. If you specify both `--ro` and
  43. `--option read-only=no`, `--ro` takes precedence.
  44. .. option:: --persistent, -p
  45. Attach device persistently, which means have it attached also after qube restart.
  46. aliases: a, at
  47. detach
  48. ^^^^^^
  49. | :command:`qvm-device` *DEVICE_CLASS* detach [-h] [--verbose] [--quiet] *VMNAME* *BACKEND_DOMAIN:DEVICE_ID*
  50. Detach the device with *BACKEND_DOMAIN:DEVICE_ID* from domain *VMNAME*
  51. aliases: d, dt
  52. Device classes
  53. ==============
  54. block
  55. ^^^^^
  56. Block device. Available options:
  57. * `frontend-dev` - device node in target domain, by default first available, starting from `xvdi`
  58. * `read-only` - attach device in read-only mode; default depends on device, if possible - attach read-write; if device itself is read-only, only read-only attach is allowed
  59. * `devtype` - type of device - either `disk` or `cdrom`; default: `disk`
  60. usb
  61. ^^^
  62. USB device. This type of device does not support options.
  63. pci
  64. ^^^
  65. PCI device. Only dom0 expose such devices. One should be very careful when attaching this type of devices, because some of them are strictly required to stay in dom0 (for example host bridge). Available options:
  66. * `no-strict-reset` - allow to attach device even if it does not support any reliable reset operation; switching such device to another domain (without full host restart) can be a security risk; default: `False`, accepted values: `True`, `False` (option absent)
  67. Authors
  68. =======
  69. | Joanna Rutkowska <joanna at invisiblethingslab dot com>
  70. | Rafal Wojtczuk <rafal at invisiblethingslab dot com>
  71. | Marek Marczykowski <marmarek at invisiblethingslab dot com>