We are facing what I am sure is an incredibly common problem: we make daily backups that result in compressed files that have the date in the file name, and we don't want to keep them forever.
Some requirements that I don't think are too extravagant:
- delete all but the last X backups / days
- keep Sunday backups
- keep the last backup of each month
- alert someone if the last backup is size 0 / more than 50% larger / smaller than the last
I tried to search on Google, but I only found a thousand scripts, many of them with obvious problems and errors. Are there no solutions & # 39; adequate & # 39; for this problem that are well tested and have a community? Am I doomed to copy and paste an OS or SU script that will not be maintained or will get bug fixes and will someday probably eat all our backups?