The deleteOldBackups function doesn't limit the depth of the file type when it is checking for older things to delete and generates a very long list of things to delete. But while it is parsing the list, it will delete children (it uses rm -rf) and items in the list to delete are no longer there. This throws ERROR messages that aren't really errors.
Adding in -maxdepth 1 ad possibly -type d would help address this.
The deleteOldBackups function doesn't limit the depth of the file type when it is checking for older things to delete and generates a very long list of things to delete. But while it is parsing the list, it will delete children (it uses
rm -rf
) and items in the list to delete are no longer there. This throws ERROR messages that aren't really errors.Adding in
-maxdepth 1
ad possibly-type d
would help address this.