You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: server/src/main/java/com/cloud/vm/snapshot/VMSnapshotManagerImpl.java
-7Lines changed: 0 additions & 7 deletions
Original file line number
Diff line number
Diff line change
@@ -764,13 +764,6 @@ public UserVm revertToSnapshot(Long vmSnapshotId) throws InsufficientCapacityExc
764
764
"In order to revert to a Snapshot without memory you need to first stop the Instance.");
765
765
}
766
766
767
-
if (userVm.getState() == VirtualMachine.State.Running && vmSnapshotVo.getType() == VMSnapshot.Type.Disk) {
768
-
thrownewInvalidParameterValueException(
769
-
"Reverting to the Instance Snapshot is not allowed for running Instances as this would result in an Instance state change. " +
770
-
"For running Instances only Snapshots with memory can be reverted. " +
771
-
"In order to revert to a Snapshot without memory you need to first stop the Instance.");
772
-
}
773
-
774
767
if (userVm.getState() == VirtualMachine.State.Stopped && vmSnapshotVo.getType() == VMSnapshot.Type.DiskAndMemory) {
775
768
thrownewInvalidParameterValueException(
776
769
"Reverting to the Instance Snapshot is not allowed for stopped Instances when the Snapshot contains memory as this would result in an Instance state change. " +
0 commit comments