diff --git a/backup-image/sync-btime.sh b/backup-image/sync-btime.sh index 4121f36..9bc7352 100755 --- a/backup-image/sync-btime.sh +++ b/backup-image/sync-btime.sh @@ -120,6 +120,12 @@ if [ $hT -eq 1 ]; then echo "Byte mismatch with $2.time !"; exit 1; fi + (sha512sum "$3/times/$2.time" > "$uuidTmp/$2.time.sum") && dd "if=$uuidTmp/$2.time.sum" bs=128 count=1 "of=$uuidTmp/$2-time.hash"; + cmp -s "$uuidTmp/$2-time.hash" "$3/hsums/$2-time.hash"; + if [ $? -ne 0 ]; then + echo "Hash mismatch with $2.time !"; + exit 1; + fi fi rm -rf $uuidTmp; echo "Finished!";