From 3fbf33753553312d6cf09a1bffcfc2358c825655 Mon Sep 17 00:00:00 2001 From: Guillaume Subiron <maethor@subiron.org> Date: Thu, 27 Feb 2025 16:31:37 +0100 Subject: [PATCH] borg: manage more error codes and to improve the output --- handlers/borg.in | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/handlers/borg.in b/handlers/borg.in index d4de31e..68fb76b 100644 --- a/handlers/borg.in +++ b/handlers/borg.in @@ -231,9 +231,13 @@ if [ "$test" = 0 ]; then warning "$output" warning "Backing up source finished with warnings." fi + elif [ "$ret" -gt 128 ]; then # borg killed by linux signal + signal=$((ret-128)) + warning "$output" + fatal "Failed backing up source. Borg killed by signal ${signal}." else # borg error error "$output" - fatal "Failed backuping up source. Borg returned exit code ${ret}." + fatal "Failed backing up source. Borg returned exit code ${ret}." fi fi -- GitLab