From fec66efe2a53c0b45db0be632747f18c875f07ec Mon Sep 17 00:00:00 2001 From: deajan Date: Sun, 30 Sep 2018 17:05:50 +0200 Subject: [PATCH] Also don't move data on file Rotation remotely --- dev/n_obackup.sh | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/dev/n_obackup.sh b/dev/n_obackup.sh index 8892408..d1bf27a 100644 --- a/dev/n_obackup.sh +++ b/dev/n_obackup.sh @@ -7,7 +7,7 @@ PROGRAM="obackup" AUTHOR="(C) 2013-2018 by Orsiris de Jong" CONTACT="http://www.netpower.fr/obackup - ozy@netpower.fr" PROGRAM_VERSION=2.1-RC1 -PROGRAM_BUILD=2018093005 +PROGRAM_BUILD=2018093006 IS_STABLE=no #### Execution order #__WITH_PARANOIA_DEBUG @@ -1710,7 +1710,8 @@ function _RotateBackupsRemoteSSH { RemoteLogger "Command was [$cmd]." "WARN" fi - elif [ "$REMOTE_OPERATION" == "yes" ]; then + else + #elif [ "$REMOTE_OPERATION" == "yes" ]; then cmd="cp -R \"$backup\" \"$backup.$PROGRAM.1\"" RemoteLogger "Launching command [$cmd]." "DEBUG" eval "$cmd" @@ -1719,14 +1720,14 @@ function _RotateBackupsRemoteSSH { RemoteLogger "Command was [$cmd]." "WARN" fi - else - cmd="mv \"$backup\" \"$backup.$PROGRAM.1\"" - RemoteLogger "Launching command [$cmd]." "DEBUG" - eval "$cmd" - if [ $? -ne 0 ]; then - RemoteLogger "Cannot move [$backup] to [$backup.$PROGRAM.1]." "ERROR" - RemoteLogger "Command was [$cmd]." "WARN" - fi + #else + # cmd="mv \"$backup\" \"$backup.$PROGRAM.1\"" + # RemoteLogger "Launching command [$cmd]." "DEBUG" + # eval "$cmd" + # if [ $? -ne 0 ]; then + # RemoteLogger "Cannot move [$backup] to [$backup.$PROGRAM.1]." "ERROR" + # RemoteLogger "Command was [$cmd]." "WARN" + # fi fi done }