Skip to content

Instantly share code, notes, and snippets.

@alexalouit
Last active February 16, 2016 09:50
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save alexalouit/27dca9eb21dbd3f5318b to your computer and use it in GitHub Desktop.
Save alexalouit/27dca9eb21dbd3f5318b to your computer and use it in GitHub Desktop.
Automatic purge of proxmox/vzdump that are aged 14 days over
#!/bin/bash
#
# cron ex: 15 5 * * * /usr/bin/nice -n 19 /usr/bin/ionice -c2 -n7 /root/scripts/vzdump-purge.sh >> /root/scripts/cron.log
path=''
# Search files more than 14 days and remove it
find $path -type f -ctime +14 -delete
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment