From 224ddd931ddc971d1ff689a4ced103ba1e33f962 Mon Sep 17 00:00:00 2001 From: Asif Bacchus Date: Fri, 26 Jul 2019 01:15:29 -0600 Subject: [PATCH] sample logrotate config --- etc/logrotate.d/pilerbackup | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 etc/logrotate.d/pilerbackup diff --git a/etc/logrotate.d/pilerbackup b/etc/logrotate.d/pilerbackup new file mode 100644 index 0000000..83f9b37 --- /dev/null +++ b/etc/logrotate.d/pilerbackup @@ -0,0 +1,15 @@ +### Rotate backup log file + +# location of log file (-l parameter of script file) +/path/to/backup.log { + + # rotate log file weekly -- you could also use 'daily', 'monthly' or + # specify a size using 'size 100k', for example + weekly + + # keep 4 weeks of old logs (4 files) and delete older ones + rotate 4 + + # compress old log files using gzip (default) + compress +} \ No newline at end of file