aboutsummaryrefslogtreecommitdiffstats
path: root/backuper.sh
diff options
context:
space:
mode:
authorGravatar Robin Obůrka <r.oburka@gmail.com> 2016-07-24 15:44:17 +0200
committerGravatar Robin Obůrka <r.oburka@gmail.com> 2016-07-24 16:34:02 +0200
commitd2b5e675b24dcfda14c1ed9a878a99bd710c4714 (patch)
tree7e3b37aabaa900789893b9899e2ac060af5e2dbe /backuper.sh
parentRemove some more debug outputs (diff)
downloadbackuper-d2b5e675b24dcfda14c1ed9a878a99bd710c4714.tar.xz
Report what failed
Diffstat (limited to 'backuper.sh')
-rw-r--r--backuper.sh6
1 files changed, 3 insertions, 3 deletions
diff --git a/backuper.sh b/backuper.sh
index ce4d2a8..eac86aa 100644
--- a/backuper.sh
+++ b/backuper.sh
@@ -184,7 +184,7 @@ add_stage() {
[ ! -p "$RUNDIR"/fifo_"$NEXTSTAGE" ] && mkfifo "$RUNDIR"/fifo_"$NEXTSTAGE"
## Run requested command and store PID
- $@ > "$RUNDIR"/fifo_"$NEXTSTAGE" < "$RUNDIR"/fifo_"$STAGE" || die &
+ $@ > "$RUNDIR"/fifo_"$NEXTSTAGE" < "$RUNDIR"/fifo_"$STAGE" || die "One of the pipeline commands failed" &
echo "$!" >> "$RUNDIR"/"$PID_FILE"
## Process started - increment
@@ -216,10 +216,10 @@ start_pipeline() {
## ... and it takes 100% CPU. So, for now: Do not use mbuffer as the last one.
#add_stage "mbuffer -q -m 100M"
- start_store || die &
+ start_store || die "Store command failed" &
PID_STORE=$!
- start_command || die &
+ start_command || die "Backup command failed" &
PID_GENERATE=$!
wait "$PID_STORE" "$PID_GENERATE"