This is an automated email from the ASF dual-hosted git repository.
rohit pushed a commit to branch 4.15
in repository https://gitbox.apache.org/repos/asf/cloudstack.git
The following commit(s) were added to refs/heads/4.15 by this push:
new f286f01 kvm: fix VM HA on zone-wide storage pools (#5164)
f286f01 is described below
commit f286f0151697ed6b05b65b8c95a89be525d38073
Author: Wei Zhou <[email protected]>
AuthorDate: Mon Jul 5 08:21:07 2021 +0200
kvm: fix VM HA on zone-wide storage pools (#5164)
---
.../kvm/src/main/java/com/cloud/ha/KVMInvestigator.java | 9 +++++++++
1 file changed, 9 insertions(+)
diff --git
a/plugins/hypervisors/kvm/src/main/java/com/cloud/ha/KVMInvestigator.java
b/plugins/hypervisors/kvm/src/main/java/com/cloud/ha/KVMInvestigator.java
index a6cddc7..a76b56a 100644
--- a/plugins/hypervisors/kvm/src/main/java/com/cloud/ha/KVMInvestigator.java
+++ b/plugins/hypervisors/kvm/src/main/java/com/cloud/ha/KVMInvestigator.java
@@ -86,6 +86,15 @@ public class KVMInvestigator extends AdapterBase implements
Investigator {
}
}
if (!hasNfs) {
+ List<StoragePoolVO> zonePools =
_storagePoolDao.findZoneWideStoragePoolsByHypervisor(agent.getDataCenterId(),
agent.getHypervisorType());
+ for (StoragePoolVO pool : zonePools) {
+ if (pool.getPoolType() == StoragePoolType.NetworkFilesystem) {
+ hasNfs = true;
+ break;
+ }
+ }
+ }
+ if (!hasNfs) {
s_logger.warn(
"Agent investigation was requested on host " + agent + ",
but host does not support investigation because it has no NFS storage. Skipping
investigation.");
return Status.Disconnected;