mirror of
https://github.com/OpenNebula/one.git
synced 2024-12-24 21:34:01 +03:00
feature #1020: Fix for better vmware disk moving
(cherry picked from commit cb5e13c149
)
This commit is contained in:
parent
047cfe4981
commit
8db6c0ed57
@ -56,5 +56,8 @@ for file in `find $RELATIVE_SRC_PATH/* -type f`; do
|
||||
exec_and_log "ln -sf ../$file $DST_PATH/$file_name"
|
||||
done
|
||||
|
||||
# Put the symlink mark for tm_mv
|
||||
exec_and_log "ln -sf $RELATIVE_SRC_PATH $DST_PATH/.disk"
|
||||
|
||||
|
||||
|
||||
|
@ -41,9 +41,11 @@ SRC_PATH=`fix_dir_slashes "$SRC_PATH"`
|
||||
|
||||
if [ "$SRC_PATH" = "$DST_PATH" ]; then
|
||||
log "Will not move, source and destination are equal"
|
||||
elif [ -f "$SRC_PATH/.disk" ]; then # This link was set in tm_ln.sh
|
||||
exec_and_log "mv $SRC_PATH/.disk $DST_PATH"
|
||||
elif echo $SRC_PATH | grep -q 'disk\.[0-9]\+$'; then
|
||||
log "Moving $SRC_PATH"
|
||||
exec_and_log "mv $SRC_PATH $DST_PATH"
|
||||
log "Moving $SRC_PATH"
|
||||
exec_and_log "mv $SRC_PATH $DST_PATH"
|
||||
elif [ -d $SRC_PATH ]; then
|
||||
log "Will not move, is not saving image"
|
||||
else
|
||||
|
Loading…
Reference in New Issue
Block a user