Skip to content

Commit cd592f5

Browse files
Prachi Damlechaturvedia
authored andcommitted
CLOUDSTACK-4528: [Vmware] new mapping vmware datacenter cloudstack zone - Virtual Router host migration across cluster FAIL
Changes: - listHosts within same cluster for migration of system and router VMs (cherry picked from commit 52f4683) Signed-off-by: animesh <animesh@apache.org>
1 parent ad3794d commit cd592f5

1 file changed

Lines changed: 7 additions & 4 deletions

File tree

‎server/src/com/cloud/server/ManagementServerImpl.java‎

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1090,10 +1090,13 @@ public Pair<List<? extends Host>, Integer> searchForServers(ListHostsCmd cmd) {
10901090

10911091
// Check if the vm can be migrated with storage.
10921092
boolean canMigrateWithStorage = false;
1093-
HypervisorCapabilitiesVO capabilities = _hypervisorCapabilitiesDao.findByHypervisorTypeAndVersion(
1094-
srcHost.getHypervisorType(), srcHost.getHypervisorVersion());
1095-
if (capabilities != null) {
1096-
canMigrateWithStorage = capabilities.isStorageMotionSupported();
1093+
1094+
if (vm.getType() == VirtualMachine.Type.User) {
1095+
HypervisorCapabilitiesVO capabilities = _hypervisorCapabilitiesDao.findByHypervisorTypeAndVersion(
1096+
srcHost.getHypervisorType(), srcHost.getHypervisorVersion());
1097+
if (capabilities != null) {
1098+
canMigrateWithStorage = capabilities.isStorageMotionSupported();
1099+
}
10971100
}
10981101

10991102
// Check if the vm is using any disks on local storage.

0 commit comments

Comments
 (0)