14.11. Storage Pool Commands
14.11. Storage Pool Commands The following commands manipulate storage pools. Using libvirt you can manage various storage solutions, including files, raw partitions, and domain-specific formats, used to provide the storage volumes visible as devices within virtual machines. For more detailed information about this feature, see more information at libvirt.org . Many of the commands for storage pools are similar to the ones used for domains. 14.11.1. Searching for a Storage Pool XML The find-storage-pool-sources type srcSpec command displays the XML describing all storage pools of a given type that could be found. If srcSpec is provided, it is a file that contains XML to further restrict the query for pools. The find-storage-pool-sources-as type host port initiator displays the XML describing all storage pools of a given type that could be found. If host , port , or initiator are provided, they control where the query is performed. The pool-info pool-or-uuid command will list the basic information about the specified storage pool object. This command requires the name or UUID of the storage pool. To retrieve this information, use the following coomand: This lists all storage pool objects known to libvirt . By default, only active pools are listed; but using the --inactive option lists just the inactive pools, and using the --all option lists all of the storage pools. In addition to those options there are several sets of filtering options that can be used to filter the content of the list. --persistent restricts the list to persistent pools, --transient restricts the list to transient pools, --autostart restricts the list to autostarting pools and finally --no-autostart restricts the list to the storage pools that have autostarting disabled. For all storage pool commands which require a type , the pool types must be separated by comma. The valid pool types include: dir , fs , netfs , logical , disk , iscsi , scsi , mpath , rbd , and sheepdog . The --details option instructs virsh to additionally display pool persistence and capacity related information where available. Note When this command is used with older servers, it is forced to use a series of API calls with an inherent race, where a pool might not be listed or might appear more than once if it changed its state between calls while the list was being collected. Newer servers however, do not have this problem. The pool-refresh pool-or-uuid refreshes the list of volumes contained in pool.
pool-list [--inactive] [--all] [--persistent] [--transient] [--autostart] [--no-autostart] [--details] type