diff --git a/src/tm_mad/ceph/cpds.ssh b/src/tm_mad/ceph/cpds.ssh index 2a649435b2..bd81ce3af7 100755 --- a/src/tm_mad/ceph/cpds.ssh +++ b/src/tm_mad/ceph/cpds.ssh @@ -97,6 +97,12 @@ if [ "${LCM_STATE}" = '26' -a "${VM_MAD}" != "kvm" ]; then exit 1 fi +# Undeployed, or stopped VM state +if [ "$LCM_STATE" = '67' ] || [ "$LCM_STATE" = '68' ]; then + error_message "cpds.ssh: Operation not supported on undeployed/stopped" + exit 1 +fi + if [ "$SNAP_ID" != "-1" ]; then error_message "cpds.ssh: Operation not supported on disk type ${TYPE} with snapshots" exit 1 diff --git a/src/tm_mad/ceph/mvds.ssh b/src/tm_mad/ceph/mvds.ssh index 7174d9f885..889ae17ac5 100755 --- a/src/tm_mad/ceph/mvds.ssh +++ b/src/tm_mad/ceph/mvds.ssh @@ -85,6 +85,17 @@ ORIGINAL_SIZE="${XPATH_ELEMENTS[j++]}" # Copy Image back to the datastore #------------------------------------------------------------------------------- +if [ "${LCM_STATE}" = '26' -a "${VM_MAD}" != "kvm" ]; then + error_message "mvds.ssh: Live operation not supported on ${VM_MAD}" + exit 1 +fi + +# Undeployed, or stopped VM state +if [ "$LCM_STATE" = '67' ] || [ "$LCM_STATE" = '68' ]; then + error_message "mvds.ssh: Operation not supported on undeployed/stopped" + exit 1 +fi + QEMU_OPTS='' if [ -n "$CEPH_USER" ]; then