增量式备份
This commit is contained in:
parent
d27e64e34c
commit
6b05afd110
@ -31,7 +31,7 @@ cd ${backUpPath}
|
||||
# 遍历60个小时前的备份文件,并将文件名存入数组
|
||||
while IFS= read -r -d '' file; do
|
||||
old_backup_files+=("$file")
|
||||
done < <(find ${backUpPath} -name "${dbName}_backUp_*.tar.gz" -type f -mmin +3600 -print0)
|
||||
done < <(find ${backUpPath} -name "${dbName}_backUp_*.tar.gz" -type f -mmin +1440 -print0)
|
||||
|
||||
# 遍历数组,删除备份文件
|
||||
for file in "${old_backup_files[@]}"; do
|
||||
|
Loading…
x
Reference in New Issue
Block a user