mirror of https://github.com/apache/cloudstack.git
bug 13551: in some case, libvirt returns storage pool available, but mount point is not there
status 13551: resolved fixed Reviewed-by: anthony
This commit is contained in:
parent
08987f0f22
commit
ee1cefcb8e
|
|
@ -339,8 +339,18 @@ public class LibvirtStorageResource {
|
|||
StoragePool sp = null;
|
||||
try {
|
||||
sp = conn.storagePoolLookupByUUIDString(spt.getUuid());
|
||||
//double check the mount point
|
||||
String targetPath = _mountPoint + File.separator + spt.getUuid();
|
||||
if (!_storageLayer.exists(targetPath)) {
|
||||
try {
|
||||
sp.destroy();
|
||||
sp.undefine();
|
||||
} catch(LibvirtException e) {
|
||||
|
||||
}
|
||||
sp = null;
|
||||
}
|
||||
} catch (LibvirtException e) {
|
||||
|
||||
}
|
||||
|
||||
if (sp == null) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue