Indunil Jayasooriya wrote:
>> In my squid.conf I have edited the line logfile_rotate 0
>> so this should prevent squid from changing access.log to access.log.1
> 
> That's true
> 
>> However for some reason it keeps doing that. Squid needs to write to
>> /var/log/squid/access.log since that is a named pipe that has a text
>> processor behind it. Any idea why Squid is still doing this ?
> 
> How's  /etc/logrotate.d/squid file. this is JUST one .
> 
> 
> Example of /etc/logrotate.d/squid
> 
> /var/log/squid/access.log {
>   daily
>   rotate 4
>   copytruncate
>   compress
>   notifempty
>   missingok
> }
> 
> /var/log/squid/cache.log {
>   daily
>   rotate 4
>   copytruncate
>   compress
>   notifempty
>   missingok
> }
> 
> /var/log/squid/store.log {
>   daily
>   rotate 4
>   copytruncate
>   compress
>   notifempty
>   missingok
> 
>   # This script asks squid to rotate its logs on its own.
>   # Restarting squid is a long process and it is not worth
>   # doing it just to rotate logs
>   postrotate
>   /usr/sbin/squid -k rotate
>   endscript
> }
> 
> As you can see, I use the /usr/sbin/squid -k rotate command to let
> squid rotate his logs. You can issue this command everytime you feel
> the need to.
Does anyone have working experience with this?
I'm wondering if the above works and want to find out why. Because last 
time I trusted logrotate like this. It renumbered the logs on me. Then 
squid -k rotate did it again. Which resulted in twice as many logs and 
every second one being empty.
Amos
-- Please use Squid 2.7.STABLE1 or 3.0.STABLE6Received on Thu Jun 05 2008 - 11:28:34 MDT
This archive was generated by hypermail 2.2.0 : Thu Jun 05 2008 - 12:00:02 MDT