mirror of
https://github.com/laurent22/rsync-time-backup
synced 2024-11-10 06:04:18 +00:00
Changed order of error/warning handling to avoid redundant error messages.
Displayed grep command that can be copied and pasted to investigate backup issues.
This commit is contained in:
parent
77d8c56000
commit
15329de603
1 changed files with 5 additions and 4 deletions
|
@ -406,14 +406,15 @@ while : ; do
|
|||
# Check whether rsync reported any errors
|
||||
# -----------------------------------------------------------------------------
|
||||
|
||||
if [ -n "$(grep "rsync:" "$LOG_FILE")" ]; then
|
||||
fn_log_warn "Rsync reported a warning, please check '$LOG_FILE' for more details."
|
||||
fi
|
||||
if [ -n "$(grep "rsync error:" "$LOG_FILE")" ]; then
|
||||
fn_log_error "Rsync reported an error, please check '$LOG_FILE' for more details."
|
||||
fn_log_error "Rsync reported an error. Run this command for more details: grep -E 'rsync:|rsync error:' '$LOG_FILE'"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ -n "$(grep "rsync:" "$LOG_FILE")" ]; then
|
||||
fn_log_warn "Rsync reported a warning. Run this command for more details: grep -E 'rsync:|rsync error:' '$LOG_FILE'"
|
||||
fi
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# Add symlink to last successful backup
|
||||
# -----------------------------------------------------------------------------
|
||||
|
|
Loading…
Reference in a new issue