Re: [squid-users] squid log rotate

From: Duane Wessels <wessels@dont-contact.us>
Date: Fri, 1 Feb 2002 09:26:24 -0700 (MST)

On Wed, 30 Jan 2002, DC wrote:

> Thanks for the mail.
> I want to know what exactly squid -k rotate does.
> Does it just delete/archive access.log and make a new
> one?
> I want calamaris r any other program to act only on
> today's logs.
> How can it be done?

  The correct way to maintain your log files is with Squid's ``rotate''
  feature. You should rotate your log files at least once per day. The
  current log files are closed and then renamed with numeric extensions
  (.0, .1, etc). If you want to, you can write your own scripts to
  archive or remove the old log files. If not, Squid will only keep up
  to logfile_rotate versions of each log file. The logfile rotation
  procedure also writes a clean swap.state file, but it does not leave
  numbered versions of the old files.

  To rotate Squid's logs, simple use this command:

          squid -k rotate

  For example, use this cron entry to rotate the logs at midnight:

          0 0 * * * /usr/local/squid/bin/squid -k rotate
Received on Fri Feb 01 2002 - 09:26:25 MST

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 17:06:07 MST