Deleting Linux Backup Easily With Rotation

Please create a cron job for the same and insert the following command.

find /data/backup/ -type f -ctime +90 -exec rm -f {} \; -print
find /data/backup/ -type d -ctime +90 -exec rm -rf {} \; -print

To check out the list of files

find /data/backup/ -ctime +90
This entry was posted in Linux. Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *

Time limit is exhausted. Please reload CAPTCHA.