mirror of https://github.com/apache/cloudstack.git
CLOUDSTACK-6046:CreateVolume from snapshot is failing with S3 as
secondary storage and zone-wide primary storage.
This commit is contained in:
parent
782c530685
commit
621276715a
|
|
@ -242,7 +242,7 @@ public class AncientDataMotionStrategy implements DataMotionStrategy {
|
|||
if (srcData.getDataStore().getRole() == DataStoreRole.Primary) {
|
||||
ep = selector.select(volObj);
|
||||
} else {
|
||||
ep = selector.select(snapObj, volObj);
|
||||
ep = selector.select(srcData, volObj);
|
||||
}
|
||||
|
||||
CopyCommand cmd = new CopyCommand(srcData.getTO(), volObj.getTO(), _createVolumeFromSnapshotWait, VirtualMachineManager.ExecuteInSequence.value());
|
||||
|
|
|
|||
|
|
@ -166,10 +166,11 @@ public class DefaultEndPointSelector implements EndPointSelector {
|
|||
poolId = destStore.getId();
|
||||
} else {
|
||||
// if both are zone scope
|
||||
selectedScope = srcScope;
|
||||
if (srcStore.getRole() == DataStoreRole.Primary) {
|
||||
selectedScope = srcScope;
|
||||
poolId = srcStore.getId();
|
||||
} else if (destStore.getRole() == DataStoreRole.Primary) {
|
||||
selectedScope = destScope;
|
||||
poolId = destStore.getId();
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue