From bea5527b30b6501e9e01f80b6d36141f069c2c90 Mon Sep 17 00:00:00 2001 From: Otho Date: Mon, 16 Jan 2023 19:42:20 -0500 Subject: [PATCH] ADded debug mode. --- backup.sh | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/backup.sh b/backup.sh index 7d7a711..9499d33 100755 --- a/backup.sh +++ b/backup.sh @@ -171,6 +171,10 @@ send_latest() for dataset in $SEND_DATASETS; do dataset=`echo $dataset|cut -d':' -f1` remote_dataset=`echo $dataset|cut -d':' -f2` + if [ $BG_DEBUG_MODE = "TRUE" ]; then + echo dataset: $dataset + echo remote dataset: $remote_dataset + fi origin_snapshot=`get_latest_snapshot $dataset` if [ $BG_TEST_MODE = "TRUE" ]; then echo zfs send $ZFS_SEND_OPTS $dataset@$origin_snapshot \| \ @@ -237,6 +241,10 @@ while :; do BG_TEST_MODE=TRUE echo Test mode. ;; + -d) + BG_DEBUG_MODE=TRUE + echo Debug mode. + ;; --) shift; break ;; esac shift