LinuxCommandLibrary

virt-xml

Edit libvirt Domain XML files with explicit command line options.

TLDR

List all the suboptions for a specific option

$ virt-xml --[option]=?
copy


List all the suboptions for disk, network, and boot
$ virt-xml --disk=? --network=? --boot=?
copy


Edit a value for a specific domain
$ virt-xml [domain] --edit --[option] [suboption]=[new_value]
copy


Change the description for a specific domain
$ virt-xml [domain] --edit --metadata description="[new_description]"
copy


Enable/Disable the boot device menu for a specific domain
$ virt-xml [domain] --edit --boot bootmenu=[on|off]
copy


Attach host USB hub to a running VM (See: tldr lsusb)
$ virt-xml [domain] --update --add-device --hostdev [bus].[device]
copy

Copied to clipboard