mirror of
https://github.com/OpenNebula/one.git
synced 2025-01-25 06:03:36 +03:00
B OpenNebula/one#6379: Fix for VM Migration failure (#2900)
using two SYSTEM_DS on same host
This commit is contained in:
parent
deb4a9d7dd
commit
58d7367556
@ -82,12 +82,14 @@ MONITOR=$(ssh_monitor_and_log "$SRC_HOST" "$MONITOR_CMD" 'Get .monitor')
|
|||||||
ssh_make_path $DST_HOST $DST_DIR
|
ssh_make_path $DST_HOST $DST_DIR
|
||||||
enable_local_monitoring $DST_HOST $DST_DIR "$MONITOR"
|
enable_local_monitoring $DST_HOST $DST_DIR "$MONITOR"
|
||||||
|
|
||||||
|
if [ "$SRC_DIR" == "$DST_DIR" ]; then
|
||||||
RANDOM_FILE=$(ssh "$DST_HOST" "mktemp -p \"$DST_DIR\"")
|
RANDOM_FILE=$(ssh "$DST_HOST" "mktemp -p \"$DST_DIR\"")
|
||||||
trap "ssh $DST_HOST \"rm -f $RANDOM_FILE\"" EXIT
|
trap "ssh $DST_HOST \"rm -f $RANDOM_FILE\"" EXIT
|
||||||
if ssh "$SRC_HOST" "test -f $RANDOM_FILE"; then
|
if ssh "$SRC_HOST" "test -f $RANDOM_FILE"; then
|
||||||
log "Not moving $SRC to $DST, they are the same path"
|
log "Not moving $SRC to $DST, they are the same path"
|
||||||
exit 0
|
exit 0
|
||||||
fi
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
log "Moving $SRC to $DST"
|
log "Moving $SRC to $DST"
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user