7b90f23b72
even if it already exists virtinst-fix-storage-pool-lookup.patch OBS-URL: https://build.opensuse.org/package/show/Virtualization/virt-manager?expand=0&rev=247
26 lines
1003 B
Diff
26 lines
1003 B
Diff
References: bsc#941464
|
|
virt-convert fails when the storage pool is already present but
|
|
is not called 'default'.
|
|
|
|
If the 'default' pool has been removed but another pool uses the
|
|
default location of /var/lib/libvirt/images virt-convert will fail
|
|
to find the pool and attempt to create another one with the same
|
|
path. This causes the conversion to fail.
|
|
Index: virt-manager-1.2.1/virtinst/storage.py
|
|
===================================================================
|
|
--- virt-manager-1.2.1.orig/virtinst/storage.py
|
|
+++ virt-manager-1.2.1/virtinst/storage.py
|
|
@@ -209,10 +209,11 @@ class StoragePool(_StorageObject):
|
|
try:
|
|
pool = conn.storagePoolLookupByName(name)
|
|
except libvirt.libvirtError:
|
|
+ pool = StoragePool.lookup_pool_by_path(conn, path)
|
|
pass
|
|
|
|
if pool:
|
|
- return
|
|
+ return StoragePool(conn, parsexml=pool.XMLDesc(0))
|
|
|
|
try:
|
|
logging.debug("Attempting to build default pool with target '%s'",
|