Hi also ,
on an other proxy though the /etc/logrotate.d/squid has the entry
weekly, the logs on there is switched daily (and also ftped to other
system for backuping there are scripts on it). The only thing it reminds
me that if there is a cron job proccessing squid -k rotate . gotta
check that i think
regards
Bora Ozden
attached mail follows:
Hi Amos,
Thanks for your answer. What i have on the /etc/logrotate.d/squid on
an Redhat Enterprise 5.2 installation is
/var/log/squid/access.log {
weekly
rotate 5
copytruncate
compress
notifempty
missingok
}
/var/log/squid/cache.log {
weekly
rotate 5
copytruncate
compress
notifempty
missingok
}
/var/log/squid/store.log {
weekly
rotate 5
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 rotater
endscript
}
I dont know all the words /options on this script. so thats what i want
to find out. when i look at the examples at google i nearly all see that
(while giving example and also troubleshooting questions) no one nearly
talks about any other path on the script except /var/log/squid
(access.log,store.log) . It sound strange to me am i the one only uses
different path for proxy logs (i use something /data...) or this script
only wants this /var/log path. Cause ill edit it to use my real
/data... path.
And also the server was giving error while making squid -k
rotate/reconfigure etc. service squid stop didnt worked and it seemed
that system couldnt find the pid of the squid (or an old pid which is
not recently used). Restarting the whole system worked and i did a
manual squid -k rotate and it made the access.log change.
Regards
Bora Ozden
Amos Jeffries wrote:
> Bora �zden wrote:
>> Hi,
>> I would like to make the squid logs to be rotated and looking at the
>> /etc/logrotate.d/squid file but not sure about all the parameters (what
>> they mean) written there. I need then make them archived (send to a
>> server via ftp, have an old script doing this at the old server , will
>> look at it and copy it to the production one) .And also when i give the
>> command
>> squid -k rotate command to rotate the log files i get " No running copy"
>> , but the proxy is working and still giving service, also can see on
>> the tail -f access.log.
>>
>> So for doing this logrotate smoothly (not to fail) i wanted also to ask
>> to the list.
>>
>> Regards
>>
>> Bora Ozden
>>
>
> Something like this:
>
> set squid.conf:
> logfile_rotate 0
>
> Then in logrotate.d/squid (this is just off the top of my head, check
> the docs for corrections):
>
> postrotate {
> squid -k rotate
> /script/to/process/logfile /var/logs/suid/access.log.1
> }
>
> Amos
Received on Fri Feb 27 2009 - 10:20:24 MST
This archive was generated by hypermail 2.2.0 : Fri Feb 27 2009 - 12:00:01 MST