Skip to content

Instantly share code, notes, and snippets.

@kurtis318
Last active May 26, 2020 20:24
Show Gist options
  • Save kurtis318/0ac6eaa56834557059b5ec56a0308f99 to your computer and use it in GitHub Desktop.
Save kurtis318/0ac6eaa56834557059b5ec56a0308f99 to your computer and use it in GitHub Desktop.
virsh cheatsheet

Here are some miscellaneous virsh commands that I use but seem to forget the syntax.

  virsh list --all                        # show list of all virtual machines/domains
  virsh start win10                       # start a vm/domain
  virsh destroy win10                     # kill (pull the power) a vm, could trash the vm
  virsh dumpxml win10 > win10.xml         # should be same as /etc/libvirt/qemu/win10.xml ??
  virsh define win10.xml                  # used to re-install vm from an xml file
  virsh undefine win10                    # deletes definition of VM
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment