diff --git a/server/src/main/java/com/cloud/hypervisor/KVMGuru.java b/server/src/main/java/com/cloud/hypervisor/KVMGuru.java index df6038d715a..c512f06a4fd 100644 --- a/server/src/main/java/com/cloud/hypervisor/KVMGuru.java +++ b/server/src/main/java/com/cloud/hypervisor/KVMGuru.java @@ -126,6 +126,10 @@ public class KVMGuru extends HypervisorGuruBase implements HypervisorGuru { @Override public Pair getCommandHostDelegation(long hostId, Command cmd) { + if (cmd instanceof StorageSubSystemCommand) { + StorageSubSystemCommand c = (StorageSubSystemCommand)cmd; + c.setExecuteInSequence(false); + } if (cmd instanceof CopyCommand) { CopyCommand c = (CopyCommand) cmd; boolean inSeq = true; @@ -137,12 +141,11 @@ public class KVMGuru extends HypervisorGuruBase implements HypervisorGuru { inSeq = false; } c.setExecuteInSequence(inSeq); + if (c.getSrcTO().getHypervisorType() == HypervisorType.KVM) { + return new Pair<>(true, hostId); + } } - if (cmd instanceof StorageSubSystemCommand) { - StorageSubSystemCommand c = (StorageSubSystemCommand)cmd; - c.setExecuteInSequence(false); - } - return new Pair(false, new Long(hostId)); + return new Pair<>(false, hostId); } @Override