Update backup script to start a new backup, but replace the old-typofix
This commit is contained in:
parent
44820bdd75
commit
654bc34204
1 changed files with 3 additions and 3 deletions
|
@ -23,10 +23,10 @@ if [[ "$?" -ne 0 ]]; then
|
|||
echo "ERROR: Backup failure"
|
||||
exit 1
|
||||
else
|
||||
if [[ -f "/var/backup/$bhost-stage4.zst" ]]; then
|
||||
rm -f "/var/backup/$bhost-stage4.zst"
|
||||
if [[ -f "/var/backup/$bhost-stage4.tar.zst" ]]; then
|
||||
rm -f "/var/backup/$bhost-stage4.tar.zst"
|
||||
fi
|
||||
mv "/var/backup/$bhost-stage4-$bdate.zst" "/var/backup/$bhost-stage4.zst"
|
||||
mv "/var/backup/$bhost-stage4-$bdate.tar.zst" "/var/backup/$bhost-stage4.tar.zst"
|
||||
fi
|
||||
|
||||
popd &>/dev/null || exit 2
|
||||
|
|
Loading…
Reference in a new issue