/logrotate.d/proftpd-basic

http://github.com/brinkman83/bashrc · #! · 37 lines · 36 code · 1 blank · 0 comment · 0 complexity · 761b01cb36ef45a9e137c74cabbad236 MD5 · raw file

  1. /var/log/proftpd/proftpd.log
  2. /var/log/proftpd/controls.log
  3. {
  4. weekly
  5. missingok
  6. rotate 7
  7. compress
  8. delaycompress
  9. notifempty
  10. create 640 root adm
  11. sharedscripts
  12. postrotate
  13. # reload could be not sufficient for all logs, a restart is safer
  14. invoke-rc.d proftpd restart 2>/dev/null >/dev/null || true
  15. endscript
  16. }
  17. /var/log/proftpd/xferlog
  18. /var/log/proftpd/xferreport
  19. {
  20. monthly
  21. missingok
  22. rotate 7
  23. compress
  24. delaycompress
  25. notifempty
  26. create 640 root adm
  27. sharedscripts
  28. prerotate
  29. endscript
  30. postrotate
  31. # reload could be not sufficient for all logs, a restart is safer
  32. invoke-rc.d proftpd restart 2>/dev/null >/dev/null || true
  33. # run ftpstats on past transfer log
  34. ftpstats -a -r -l 2 -d -h -f /var/log/proftpd/xferlog.0 2>/dev/null >/var/log/proftpd/xferreport || true
  35. endscript
  36. }