Améliorations du suivi de la sync

This commit is contained in:
Adrien Bourmault 2023-11-22 09:24:57 +01:00 committed by admin666
parent d3bbc17d17
commit a92a255d3c
1 changed files with 3 additions and 1 deletions

View File

@ -24,6 +24,7 @@ trap clean_exit INT
function clean_exit() {
echo "Exiting..."
set +e
umount -q /mnt/${vm}
umount -q /mnt/${vm}-remote
sync
@ -33,6 +34,7 @@ function clean_exit() {
fi
sleep 3
rmdir /mnt/${vm}*
exit 0
}
@ -90,7 +92,7 @@ borg mount root@${backuphost}:/var/backups/borg/${vm}.repo::${DATES[backupdate]}
# Syncing
echo "Syncing now !"
sleep 1
rsync -ar --progress --sparse /mnt/${vm}-remote/. /mnt/${vm}
rsync -ar --info=progress2 --no-i-r --sparse /mnt/${vm}-remote/. /mnt/${vm}
# Cleaning up
echo -e "\nOK\n"