[squid-users] Re: Squid permission on log files

From: Bisal <bishal@dont-contact.us>
Date: Thu, 07 Sep 2006 17:08:13 +0545

Thanks for your quicker replies.

              Actually there is nothing except "squid -k rotate" lines
inside that script. Below is my script line

#!/bin/sh

squid -k rotate

chmod 644 /var/log/squid/access.log

---------------------------------------

By writing the line in /etc/newsyslog.conf file, there is a problem, I
have to sighup the squid process manually. Any other tips so that log
files will be rotated automatically without changing the read permission
for the file?

Thanks
Bsal

On 9/7/2006, "Odhiambo WASHINGTON" <odhiambo.raburu@wananchi.com> wrote:

>* On 07/09/06 07:48 -0000, bishal@baayu.com.np wrote:
>|
>| Hi
>|
>|
>| I have installed squid 2.6.3 on freebsd server 5. My problem is, I have
>|
>| created a cron script to rotate the log files everynight. When ever this
>|
>| cron run and new log file is created, the permission for the file is
>|
>| also changed. I cannot view the access.log file. And I have to change
>|
>| its permission manually.
>|
>|
>| Can anyone tell me what's wrong?
>
>
>Why don't you simply run `squid -k rotate`. It's enough, at least from
>the details you've given.
>
>If you want a finer control, add the following to /etc/newsyslog.conf:
>
>/usr/local/squid/logs/access.log squid:squid 644 7 * @T00 J
/usr/local/squid/logs/squid.pid 30
>
>
>You need to send squid SIGUSR1 (signal 30) to tell it to reopen its
>logfiles.
>
>PS: Next time, it would be safe for you to assume that we all broke our
>crystal glasses, so we cannot "see" what is wrong with your script
>unless you show it to us.
>
>
>-Wash
>
>http://www.netmeister.org/news/learn2quote.html
>
>DISCLAIMER: See http://www.wananchi.com/bms/terms.php
>
>--
>+======================================================================+
> |\ _,,,---,,_ | Odhiambo Washington <wash@wananchi.com>
>Zzz /,`.-'`' -. ;-;;,_ | Wananchi Online Ltd. www.wananchi.com
> |,4- ) )-,_. ,\ ( `'-'| Tel: +254 20 313985-9 +254 20 313922
> '---''(_/--' `-'\_) | GSM: +254 722 743223 +254 733 744121
>+======================================================================+
>
>"Nirvana? Thats the place where the powers that be and their friends
>hang out.
> -- Zonker Harris
>
>
Received on Thu Sep 07 2006 - 05:23:46 MDT

This archive was generated by hypermail pre-2.1.9 : Sun Oct 01 2006 - 12:00:03 MDT