SARG reports for Squid filling up the disk, how to purge them?

Solution 1:

There is a configuration option lastlog for /etc/squid/sarg.conf that allows you to specify how many days worth of logs to keep e.g.

lastlog 45

to keep 45 days worth of logs. The default is 0 which means keep all logs.


# TAG: lastlog n
#      How many reports files must be keept in reports directory.
#      The oldest report file will be automatically removed.
#      0 - no limit.
#
lastlog 0