diff --git a/engine/orchestration/src/main/java/com/cloud/vm/VirtualMachineManagerImpl.java b/engine/orchestration/src/main/java/com/cloud/vm/VirtualMachineManagerImpl.java index 0613b9586ff..09c3e37bed9 100755 --- a/engine/orchestration/src/main/java/com/cloud/vm/VirtualMachineManagerImpl.java +++ b/engine/orchestration/src/main/java/com/cloud/vm/VirtualMachineManagerImpl.java @@ -3007,7 +3007,7 @@ public class VirtualMachineManagerImpl extends ManagerBase implements VirtualMac executeManagedStorageChecksWhenTargetStoragePoolNotProvided(targetHost, currentPool, volume); if (ScopeType.HOST.equals(currentPool.getScope()) || isStorageCrossClusterMigration(plan.getClusterId(), currentPool)) { createVolumeToStoragePoolMappingIfPossible(profile, plan, volumeToPoolObjectMap, volume, currentPool); - } else if (shouldMapVolume(profile, volume, currentPool)){ + } else if (shouldMapVolume(profile, currentPool)){ volumeToPoolObjectMap.put(volume, currentPool); } } @@ -3019,11 +3019,10 @@ public class VirtualMachineManagerImpl extends ManagerBase implements VirtualMac * Some context: VMware migration workflow requires all volumes to be mapped (even if volume stays on its current pool); * however, this is not necessary/desirable for the KVM flow. */ - protected boolean shouldMapVolume(VirtualMachineProfile profile, Volume volume, StoragePoolVO currentPool) { + protected boolean shouldMapVolume(VirtualMachineProfile profile, StoragePoolVO currentPool) { boolean isManaged = currentPool.isManaged(); boolean isNotKvm = HypervisorType.KVM != profile.getHypervisorType(); - boolean isNotDatadisk = Type.DATADISK != volume.getVolumeType(); - return isNotKvm || isNotDatadisk || isManaged; + return isNotKvm || isManaged; } /**