diff --git a/plugins/hypervisors/xen/src/org/apache/cloudstack/storage/motion/XenServerStorageMotionStrategy.java b/plugins/hypervisors/xen/src/org/apache/cloudstack/storage/motion/XenServerStorageMotionStrategy.java index 353f2b58d08..42cb68d1213 100644 --- a/plugins/hypervisors/xen/src/org/apache/cloudstack/storage/motion/XenServerStorageMotionStrategy.java +++ b/plugins/hypervisors/xen/src/org/apache/cloudstack/storage/motion/XenServerStorageMotionStrategy.java @@ -19,8 +19,8 @@ package org.apache.cloudstack.storage.motion; import java.util.HashMap; -import java.util.Map; import java.util.List; +import java.util.Map; import javax.inject.Inject; @@ -50,6 +50,7 @@ import com.cloud.agent.api.to.VolumeTO; import com.cloud.exception.AgentUnavailableException; import com.cloud.exception.OperationTimedoutException; import com.cloud.host.Host; +import com.cloud.hypervisor.Hypervisor.HypervisorType; import com.cloud.storage.StoragePool; import com.cloud.storage.VolumeVO; import com.cloud.storage.dao.VolumeDao; @@ -73,7 +74,12 @@ public class XenServerStorageMotionStrategy implements DataMotionStrategy { @Override public boolean canHandle(Map volumeMap, Host srcHost, Host destHost) { - return true; + boolean canHandle = false; + if (srcHost.getHypervisorType() == HypervisorType.XenServer && + destHost.getHypervisorType() == HypervisorType.XenServer) { + canHandle = true; + } + return canHandle; } @Override