From 4059c5e12e671cef6553f4bc3a134a5c570fdf5a Mon Sep 17 00:00:00 2001 From: Alexander Barton Date: Wed, 4 May 2011 17:47:26 +0200 Subject: [PATCH] New config option "ping" Default ist "1", ping the remote host to check if it is alive. Set to "0" to always force rsync(1) to start. --- bin/backup-script | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/bin/backup-script b/bin/backup-script index 21685f8..d1164a0 100755 --- a/bin/backup-script +++ b/bin/backup-script @@ -130,6 +130,7 @@ for f in $sys; do ssh_args_add="" rsync_args_add="" compress=1 + ping=1 local=0 case "$system" in @@ -161,7 +162,7 @@ for f in $sys; do target="$target/$system" mkdir -p "$target" - if [ "$local" -eq 0 ]; then + if [ "$local" -eq 0 -a "$ping" -ne 0 ]; then # Check if system is alive ping -c 1 "$system" >/dev/null 2>&1 if [ $? -ne 0 ]; then -- 2.39.2