Re: [squid-users] Logrotate question

2022-06-17 Thread Amos Jeffries

On 18/06/22 11:25, robert k Wild wrote:

So what your saying is change the
-k reconfigure to
-k rotate

Even tho I've configured squid from source



Yes.

Amos
___
squid-users mailing list
squid-users@lists.squid-cache.org
http://lists.squid-cache.org/listinfo/squid-users


Re: [squid-users] Logrotate question

2022-06-17 Thread robert k Wild
So what your saying is change the
-k reconfigure to
-k rotate

Even tho I've configured squid from source

On Sat, 18 Jun 2022, 00:17 Amos Jeffries,  wrote:

> On 18/06/22 07:06, robert k Wild wrote:
> >   i understand it now
> >
>
> Er, no.
>
> > cat /etc/logrotate.d/squid
> > /usr/local/squid/var/logs/*.log {
> ...
> > postrotate
> > /usr/local/squid/sbin/squid -k reconfigure
> > endscript
> > }
> >
> > needed the sharedscripts to run the postrotate just once for all logs
> >
> > didnt need the squid -k rotate as already handled by logrotate
> >
>
> The "-k rotate" tells Squid to open and start writing to the new log
> files created by logrotate tool.
>
> That "-k reconfigure" you have chosen is a far more complicated and slow
> operation. It is not guaranteed to change the files Squid is writing to.
>
>
> PS. you also need to configure "logfile_rotate 0" for self-built Squid
> to prevent it doing any log file renumbering when logrotated is used.
>
> Amos
> ___
> squid-users mailing list
> squid-users@lists.squid-cache.org
> http://lists.squid-cache.org/listinfo/squid-users
>
___
squid-users mailing list
squid-users@lists.squid-cache.org
http://lists.squid-cache.org/listinfo/squid-users


Re: [squid-users] Logrotate question

2022-06-17 Thread Amos Jeffries

On 18/06/22 07:06, robert k Wild wrote:

  i understand it now



Er, no.


cat /etc/logrotate.d/squid
/usr/local/squid/var/logs/*.log {

...

postrotate
/usr/local/squid/sbin/squid -k reconfigure
endscript
}

needed the sharedscripts to run the postrotate just once for all logs

didnt need the squid -k rotate as already handled by logrotate



The "-k rotate" tells Squid to open and start writing to the new log 
files created by logrotate tool.


That "-k reconfigure" you have chosen is a far more complicated and slow 
operation. It is not guaranteed to change the files Squid is writing to.



PS. you also need to configure "logfile_rotate 0" for self-built Squid 
to prevent it doing any log file renumbering when logrotated is used.


Amos
___
squid-users mailing list
squid-users@lists.squid-cache.org
http://lists.squid-cache.org/listinfo/squid-users


Re: [squid-users] Logrotate question

2022-06-17 Thread robert k Wild
 i understand it now

cat /etc/logrotate.d/squid
/usr/local/squid/var/logs/*.log {
monthly
rotate 4
compress
delaycompress
missingok
sharedscripts
dateext
dateformat -%d%m%Y
su root root
postrotate
/usr/local/squid/sbin/squid -k reconfigure
endscript
}

needed the sharedscripts to run the postrotate just once for all logs

didnt need the squid -k rotate as already handled by logrotate

On Fri, 17 Jun 2022 at 19:27, robert k Wild  wrote:

> just a question, im just playing with logrotate
>
> /usr/local/squid/var/logs/*.log {
> monthly
> rotate 4
> compress
> delaycompress
> missingok
> dateext
> dateformat -%d%m%Y
> su root root
> postrotate
> /usr/local/squid/sbin/squid -k reconfigure
> endscript
> }
>
> why is the "squid -k rotate" listed under "postrotate" as logrotate is
> handling it
>
> On Thu, 16 Jun 2022 at 14:06, robert k Wild  wrote:
>
>> Thanks Eliezer, really appreciate it :)
>>
>> On Thu, 16 Jun 2022, 14:03 ,  wrote:
>>
>>> So just create the file I sent you before or extract the file from the
>>> squid RPM using “rpm2cpio squid…rpm |cpio -dimv” in some tmp dir.
>>>
>>> You will just need to copy the file into the proper location, disable
>>> the cron you have created and if the squid binary is in a specific
>>> different folder change the path of the squid binary in the squid
>>> logrotate file accordingly.
>>>
>>>
>>>
>>> All The Bests,
>>>
>>> Eliezer
>>>
>>>
>>>
>>> *From:* robert k Wild 
>>> *Sent:* Thursday, 16 June 2022 15:24
>>> *To:* Eliezer Croitoru 
>>> *Cc:* Squid Users 
>>> *Subject:* Re: [squid-users] Logrotate question
>>>
>>>
>>>
>>> No squid isn't sorry it is compiled from source, I forgot to add it
>>> sorry about that
>>>
>>>
>>>
>>> On Thu, 16 Jun 2022, 13:19 ,  wrote:
>>>
>>> Since this one is from yum install it’s very simple to just change the
>>> config files of squid and logrotate.
>>>
>>>
>>>
>>> If you need more assistance let me know.
>>>
>>>
>>>
>>> Eliezer
>>>
>>>
>>>
>>> *From:* robert k Wild 
>>> *Sent:* Thursday, 16 June 2022 14:52
>>> *To:* Eliezer Croitoru 
>>> *Cc:* Squid Users 
>>> *Subject:* Re: [squid-users] Logrotate question
>>>
>>>
>>>
>>> Self compiled from source with others ie
>>>
>>>
>>>
>>> Squidclamav
>>>
>>> Cicap
>>>
>>> Cicap modules
>>>
>>>
>>>
>>> And clamav but did this one via yum install
>>>
>>>
>>>
>>>
>>>
>>> On Thu, 16 Jun 2022, 12:27 ,  wrote:
>>>
>>> How did you installed squid on CentOS 7?
>>>
>>> From my packages or the OS default or self compiled or another source?
>>>
>>>
>>>
>>> Eliezer
>>>
>>>
>>>
>>> *From:* robert k Wild 
>>> *Sent:* Thursday, 16 June 2022 14:05
>>> *To:* Eliezer Croitoru 
>>> *Cc:* Squid Users 
>>> *Subject:* Re: [squid-users] Logrotate question
>>>
>>>
>>>
>>> Oops sorry you did say that, sorry I didn't see that at first
>>>
>>>
>>>
>>> On Thu, 16 Jun 2022, 12:04 robert k Wild,  wrote:
>>>
>>> I imagine Eliezer that's what I need to put in logrotate.conf file
>>>
>>>
>>>
>>> On Thu, 16 Jun 2022, 12:01 ,  wrote:
>>>
>>> Oops,
>>>
>>>
>>>
>>> The next is the file: /etc/logrotate.d/squid
>>>
>>> ##START
>>>
>>> /var/log/squid/*.log {
>>>
>>> weekly
>>>
>>> rotate 5
>>>
>>> compress
>>>
>>> notifempty
>>>
>>> missingok
>>>
>>> nocreate
>>>
>>> sharedscripts
>>>
>>> postrotate
>>>
>>>   # Asks squid to reopen its logs. (logfile_rotate 0 is set in
>>> squid.conf)
>>>
>>>   # errors redirected to make it silent if squid is not running
>>>
>>>   /usr/sbin/squid -k rotate 2>/dev/null
>>>
>>>   # Wait a little to allow Squid to catch up before the logs is
>>> compressed
>>>
>>>   sleep 1
>>>
>>> endscript
&g

Re: [squid-users] Logrotate question

2022-06-17 Thread robert k Wild
just a question, im just playing with logrotate

/usr/local/squid/var/logs/*.log {
monthly
rotate 4
compress
delaycompress
missingok
dateext
dateformat -%d%m%Y
su root root
postrotate
/usr/local/squid/sbin/squid -k reconfigure
endscript
}

why is the "squid -k rotate" listed under "postrotate" as logrotate is
handling it

On Thu, 16 Jun 2022 at 14:06, robert k Wild  wrote:

> Thanks Eliezer, really appreciate it :)
>
> On Thu, 16 Jun 2022, 14:03 ,  wrote:
>
>> So just create the file I sent you before or extract the file from the
>> squid RPM using “rpm2cpio squid…rpm |cpio -dimv” in some tmp dir.
>>
>> You will just need to copy the file into the proper location, disable the
>> cron you have created and if the squid binary is in a specific different
>> folder change the path of the squid binary in the squid logrotate file
>> accordingly.
>>
>>
>>
>> All The Bests,
>>
>> Eliezer
>>
>>
>>
>> *From:* robert k Wild 
>> *Sent:* Thursday, 16 June 2022 15:24
>> *To:* Eliezer Croitoru 
>> *Cc:* Squid Users 
>> *Subject:* Re: [squid-users] Logrotate question
>>
>>
>>
>> No squid isn't sorry it is compiled from source, I forgot to add it sorry
>> about that
>>
>>
>>
>> On Thu, 16 Jun 2022, 13:19 ,  wrote:
>>
>> Since this one is from yum install it’s very simple to just change the
>> config files of squid and logrotate.
>>
>>
>>
>> If you need more assistance let me know.
>>
>>
>>
>> Eliezer
>>
>>
>>
>> *From:* robert k Wild 
>> *Sent:* Thursday, 16 June 2022 14:52
>> *To:* Eliezer Croitoru 
>> *Cc:* Squid Users 
>> *Subject:* Re: [squid-users] Logrotate question
>>
>>
>>
>> Self compiled from source with others ie
>>
>>
>>
>> Squidclamav
>>
>> Cicap
>>
>> Cicap modules
>>
>>
>>
>> And clamav but did this one via yum install
>>
>>
>>
>>
>>
>> On Thu, 16 Jun 2022, 12:27 ,  wrote:
>>
>> How did you installed squid on CentOS 7?
>>
>> From my packages or the OS default or self compiled or another source?
>>
>>
>>
>> Eliezer
>>
>>
>>
>> *From:* robert k Wild 
>> *Sent:* Thursday, 16 June 2022 14:05
>> *To:* Eliezer Croitoru 
>> *Cc:* Squid Users 
>> *Subject:* Re: [squid-users] Logrotate question
>>
>>
>>
>> Oops sorry you did say that, sorry I didn't see that at first
>>
>>
>>
>> On Thu, 16 Jun 2022, 12:04 robert k Wild,  wrote:
>>
>> I imagine Eliezer that's what I need to put in logrotate.conf file
>>
>>
>>
>> On Thu, 16 Jun 2022, 12:01 ,  wrote:
>>
>> Oops,
>>
>>
>>
>> The next is the file: /etc/logrotate.d/squid
>>
>> ##START
>>
>> /var/log/squid/*.log {
>>
>> weekly
>>
>> rotate 5
>>
>> compress
>>
>> notifempty
>>
>> missingok
>>
>> nocreate
>>
>>     sharedscripts
>>
>> postrotate
>>
>>   # Asks squid to reopen its logs. (logfile_rotate 0 is set in
>> squid.conf)
>>
>>   # errors redirected to make it silent if squid is not running
>>
>>   /usr/sbin/squid -k rotate 2>/dev/null
>>
>>   # Wait a little to allow Squid to catch up before the logs is
>> compressed
>>
>>   sleep 1
>>
>> endscript
>>
>> }
>>
>> ##END
>>
>>
>>
>> So you need to change the rotate to 92+ and also change the squid number
>> of logs to the same number.
>>
>>
>>
>> Let me know if you it’s helpful.
>>
>>
>>
>> Eliezer
>>
>>
>>
>> *From:* ngtech1...@gmail.com 
>> *Sent:* Thursday, 16 June 2022 14:00
>> *To:* 'robert k Wild' ; 'Squid Users' <
>> squid-users@lists.squid-cache.org>
>> *Subject:* RE: [squid-users] Logrotate question
>>
>>
>>
>> Hey Rob,
>>
>>
>>
>> The next is the file:
>>
>>
>>
>>
>>
>> *From:* squid-users  *On
>> Behalf Of *robert k Wild
>> *Sent:* Thursday, 16 June 2022 13:27
>> *To:* Squid Users 
>> *Subject:* Re: [squid-users] Logrotate question
>>
>>
>>
>> Cool, so I will rotate daily and delete after 91 days, thanks guys
>>
>>
>>
>> On Thu, 16 Jun 2022, 11:14 Matus UHLAR - fantomas, 
>> wrote:
&

Re: [squid-users] Logrotate question

2022-06-16 Thread robert k Wild
Thanks Eliezer, really appreciate it :)

On Thu, 16 Jun 2022, 14:03 ,  wrote:

> So just create the file I sent you before or extract the file from the
> squid RPM using “rpm2cpio squid…rpm |cpio -dimv” in some tmp dir.
>
> You will just need to copy the file into the proper location, disable the
> cron you have created and if the squid binary is in a specific different
> folder change the path of the squid binary in the squid logrotate file
> accordingly.
>
>
>
> All The Bests,
>
> Eliezer
>
>
>
> *From:* robert k Wild 
> *Sent:* Thursday, 16 June 2022 15:24
> *To:* Eliezer Croitoru 
> *Cc:* Squid Users 
> *Subject:* Re: [squid-users] Logrotate question
>
>
>
> No squid isn't sorry it is compiled from source, I forgot to add it sorry
> about that
>
>
>
> On Thu, 16 Jun 2022, 13:19 ,  wrote:
>
> Since this one is from yum install it’s very simple to just change the
> config files of squid and logrotate.
>
>
>
> If you need more assistance let me know.
>
>
>
> Eliezer
>
>
>
> *From:* robert k Wild 
> *Sent:* Thursday, 16 June 2022 14:52
> *To:* Eliezer Croitoru 
> *Cc:* Squid Users 
> *Subject:* Re: [squid-users] Logrotate question
>
>
>
> Self compiled from source with others ie
>
>
>
> Squidclamav
>
> Cicap
>
> Cicap modules
>
>
>
> And clamav but did this one via yum install
>
>
>
>
>
> On Thu, 16 Jun 2022, 12:27 ,  wrote:
>
> How did you installed squid on CentOS 7?
>
> From my packages or the OS default or self compiled or another source?
>
>
>
> Eliezer
>
>
>
> *From:* robert k Wild 
> *Sent:* Thursday, 16 June 2022 14:05
> *To:* Eliezer Croitoru 
> *Cc:* Squid Users 
> *Subject:* Re: [squid-users] Logrotate question
>
>
>
> Oops sorry you did say that, sorry I didn't see that at first
>
>
>
> On Thu, 16 Jun 2022, 12:04 robert k Wild,  wrote:
>
> I imagine Eliezer that's what I need to put in logrotate.conf file
>
>
>
> On Thu, 16 Jun 2022, 12:01 ,  wrote:
>
> Oops,
>
>
>
> The next is the file: /etc/logrotate.d/squid
>
> ##START
>
> /var/log/squid/*.log {
>
> weekly
>
> rotate 5
>
> compress
>
> notifempty
>
> missingok
>
> nocreate
>
> sharedscripts
>
> postrotate
>
>   # Asks squid to reopen its logs. (logfile_rotate 0 is set in
> squid.conf)
>
>   # errors redirected to make it silent if squid is not running
>
>   /usr/sbin/squid -k rotate 2>/dev/null
>
>   # Wait a little to allow Squid to catch up before the logs is
> compressed
>
>   sleep 1
>
> endscript
>
> }
>
> ##END
>
>
>
> So you need to change the rotate to 92+ and also change the squid number
> of logs to the same number.
>
>
>
> Let me know if you it’s helpful.
>
>
>
> Eliezer
>
>
>
> *From:* ngtech1...@gmail.com 
> *Sent:* Thursday, 16 June 2022 14:00
> *To:* 'robert k Wild' ; 'Squid Users' <
> squid-users@lists.squid-cache.org>
> *Subject:* RE: [squid-users] Logrotate question
>
>
>
> Hey Rob,
>
>
>
> The next is the file:
>
>
>
>
>
> *From:* squid-users  *On
> Behalf Of *robert k Wild
> *Sent:* Thursday, 16 June 2022 13:27
> *To:* Squid Users 
> *Subject:* Re: [squid-users] Logrotate question
>
>
>
> Cool, so I will rotate daily and delete after 91 days, thanks guys
>
>
>
> On Thu, 16 Jun 2022, 11:14 Matus UHLAR - fantomas, 
> wrote:
>
> On 16.06.22 10:54, robert k Wild wrote:
> >Basically I want to keep logs for 3 months then rotate so it overwrites
> >them with another 3 months, if that makes sense
>
> in fact, it does not.
>
> I guess you are supposed to keep 3 months of logs, which mean, you always
> need to have 3 months of logs available.
>
> Each day, you can delete log files over 3 months old.
>
> If you rotated lof once in 3 months, you would have single file with 3
> months of logs in it, and could remove it 3 months after rotating, when
> first logs would be 6 months old.
>
> As we already told you, rotate daily and remove old logs after 92 days.
> and use logrotate config.
>
> --
> Matus UHLAR - fantomas, uh...@fantomas.sk ; http://www.fantomas.sk/
> Warning: I wish NOT to receive e-mail advertising to this address.
> Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.
> Linux - It's now safe to turn on your computer.
> Linux - Teraz mozete pocitac bez obav zapnut.
> ___
> squid-users mailing list
> squid-users@lists.squid-cache.org
> http://lists.squid-cache.org/listinfo/squid-users
>
>
___
squid-users mailing list
squid-users@lists.squid-cache.org
http://lists.squid-cache.org/listinfo/squid-users


Re: [squid-users] Logrotate question

2022-06-16 Thread ngtech1ltd
So just create the file I sent you before or extract the file from the squid 
RPM using “rpm2cpio squid…rpm |cpio -dimv” in some tmp dir.
You will just need to copy the file into the proper location, disable the cron 
you have created and if the squid binary is in a specific different folder 
change the path of the squid binary in the squid logrotate file accordingly.
 
All The Bests,
Eliezer
 
From: robert k Wild  
Sent: Thursday, 16 June 2022 15:24
To: Eliezer Croitoru 
Cc: Squid Users 
Subject: Re: [squid-users] Logrotate question
 
No squid isn't sorry it is compiled from source, I forgot to add it sorry about 
that
 
On Thu, 16 Jun 2022, 13:19 , mailto:ngtech1...@gmail.com> > wrote:
Since this one is from yum install it’s very simple to just change the config 
files of squid and logrotate.
 
If you need more assistance let me know.
 
Eliezer
 
From: robert k Wild mailto:robertkw...@gmail.com> > 
Sent: Thursday, 16 June 2022 14:52
To: Eliezer Croitoru mailto:ngtech1...@gmail.com> >
Cc: Squid Users mailto:squid-users@lists.squid-cache.org> >
Subject: Re: [squid-users] Logrotate question
 
Self compiled from source with others ie
 
Squidclamav
Cicap
Cicap modules
 
And clamav but did this one via yum install
 
 
On Thu, 16 Jun 2022, 12:27 , mailto:ngtech1...@gmail.com> > wrote:
How did you installed squid on CentOS 7?
>From my packages or the OS default or self compiled or another source?
 
Eliezer
 
From: robert k Wild mailto:robertkw...@gmail.com> > 
Sent: Thursday, 16 June 2022 14:05
To: Eliezer Croitoru mailto:ngtech1...@gmail.com> >
Cc: Squid Users mailto:squid-users@lists.squid-cache.org> >
Subject: Re: [squid-users] Logrotate question
 
Oops sorry you did say that, sorry I didn't see that at first
 
On Thu, 16 Jun 2022, 12:04 robert k Wild, mailto:robertkw...@gmail.com> > wrote:
I imagine Eliezer that's what I need to put in logrotate.conf file
 
On Thu, 16 Jun 2022, 12:01 , mailto:ngtech1...@gmail.com> > wrote:
Oops,
 
The next is the file: /etc/logrotate.d/squid
##START
/var/log/squid/*.log {
weekly
rotate 5
compress
notifempty
missingok
nocreate
sharedscripts
postrotate
  # Asks squid to reopen its logs. (logfile_rotate 0 is set in squid.conf)
  # errors redirected to make it silent if squid is not running
  /usr/sbin/squid -k rotate 2>/dev/null
  # Wait a little to allow Squid to catch up before the logs is compressed
  sleep 1
endscript
}
##END
 
So you need to change the rotate to 92+ and also change the squid number of 
logs to the same number.
 
Let me know if you it’s helpful.
 
Eliezer
 
From: ngtech1...@gmail.com <mailto:ngtech1...@gmail.com>  mailto:ngtech1...@gmail.com> > 
Sent: Thursday, 16 June 2022 14:00
To: 'robert k Wild' mailto:robertkw...@gmail.com> >; 
'Squid Users' 
Subject: RE: [squid-users] Logrotate question
 
Hey Rob,
 
The next is the file:
 
 
From: squid-users mailto:squid-users-boun...@lists.squid-cache.org> > On Behalf Of robert k Wild
Sent: Thursday, 16 June 2022 13:27
To: Squid Users mailto:squid-users@lists.squid-cache.org> >
Subject: Re: [squid-users] Logrotate question
 
Cool, so I will rotate daily and delete after 91 days, thanks guys
 
On Thu, 16 Jun 2022, 11:14 Matus UHLAR - fantomas, mailto:uh...@fantomas.sk> > wrote:
On 16.06.22 10:54, robert k Wild wrote:
>Basically I want to keep logs for 3 months then rotate so it overwrites
>them with another 3 months, if that makes sense

in fact, it does not.

I guess you are supposed to keep 3 months of logs, which mean, you always 
need to have 3 months of logs available.

Each day, you can delete log files over 3 months old.

If you rotated lof once in 3 months, you would have single file with 3 
months of logs in it, and could remove it 3 months after rotating, when 
first logs would be 6 months old.

As we already told you, rotate daily and remove old logs after 92 days.
and use logrotate config.

-- 
Matus UHLAR - fantomas, uh...@fantomas.sk <mailto:uh...@fantomas.sk>  ; 
http://www.fantomas.sk/
Warning: I wish NOT to receive e-mail advertising to this address.
Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.
Linux - It's now safe to turn on your computer.
Linux - Teraz mozete pocitac bez obav zapnut.
___
squid-users mailing list
squid-users@lists.squid-cache.org <mailto:squid-users@lists.squid-cache.org> 
http://lists.squid-cache.org/listinfo/squid-users
___
squid-users mailing list
squid-users@lists.squid-cache.org
http://lists.squid-cache.org/listinfo/squid-users


Re: [squid-users] Logrotate question

2022-06-16 Thread robert k Wild
No squid isn't sorry it is compiled from source, I forgot to add it sorry
about that

On Thu, 16 Jun 2022, 13:19 ,  wrote:

> Since this one is from yum install it’s very simple to just change the
> config files of squid and logrotate.
>
>
>
> If you need more assistance let me know.
>
>
>
> Eliezer
>
>
>
> *From:* robert k Wild 
> *Sent:* Thursday, 16 June 2022 14:52
> *To:* Eliezer Croitoru 
> *Cc:* Squid Users 
> *Subject:* Re: [squid-users] Logrotate question
>
>
>
> Self compiled from source with others ie
>
>
>
> Squidclamav
>
> Cicap
>
> Cicap modules
>
>
>
> And clamav but did this one via yum install
>
>
>
>
>
> On Thu, 16 Jun 2022, 12:27 ,  wrote:
>
> How did you installed squid on CentOS 7?
>
> From my packages or the OS default or self compiled or another source?
>
>
>
> Eliezer
>
>
>
> *From:* robert k Wild 
> *Sent:* Thursday, 16 June 2022 14:05
> *To:* Eliezer Croitoru 
> *Cc:* Squid Users 
> *Subject:* Re: [squid-users] Logrotate question
>
>
>
> Oops sorry you did say that, sorry I didn't see that at first
>
>
>
> On Thu, 16 Jun 2022, 12:04 robert k Wild,  wrote:
>
> I imagine Eliezer that's what I need to put in logrotate.conf file
>
>
>
> On Thu, 16 Jun 2022, 12:01 ,  wrote:
>
> Oops,
>
>
>
> The next is the file: /etc/logrotate.d/squid
>
> ##START
>
> /var/log/squid/*.log {
>
> weekly
>
> rotate 5
>
> compress
>
> notifempty
>
> missingok
>
> nocreate
>
> sharedscripts
>
> postrotate
>
>   # Asks squid to reopen its logs. (logfile_rotate 0 is set in
> squid.conf)
>
>   # errors redirected to make it silent if squid is not running
>
>   /usr/sbin/squid -k rotate 2>/dev/null
>
>   # Wait a little to allow Squid to catch up before the logs is
> compressed
>
>   sleep 1
>
> endscript
>
> }
>
> ##END
>
>
>
> So you need to change the rotate to 92+ and also change the squid number
> of logs to the same number.
>
>
>
> Let me know if you it’s helpful.
>
>
>
> Eliezer
>
>
>
> *From:* ngtech1...@gmail.com 
> *Sent:* Thursday, 16 June 2022 14:00
> *To:* 'robert k Wild' ; 'Squid Users' <
> squid-users@lists.squid-cache.org>
> *Subject:* RE: [squid-users] Logrotate question
>
>
>
> Hey Rob,
>
>
>
> The next is the file:
>
>
>
>
>
> *From:* squid-users  *On
> Behalf Of *robert k Wild
> *Sent:* Thursday, 16 June 2022 13:27
> *To:* Squid Users 
> *Subject:* Re: [squid-users] Logrotate question
>
>
>
> Cool, so I will rotate daily and delete after 91 days, thanks guys
>
>
>
> On Thu, 16 Jun 2022, 11:14 Matus UHLAR - fantomas, 
> wrote:
>
> On 16.06.22 10:54, robert k Wild wrote:
> >Basically I want to keep logs for 3 months then rotate so it overwrites
> >them with another 3 months, if that makes sense
>
> in fact, it does not.
>
> I guess you are supposed to keep 3 months of logs, which mean, you always
> need to have 3 months of logs available.
>
> Each day, you can delete log files over 3 months old.
>
> If you rotated lof once in 3 months, you would have single file with 3
> months of logs in it, and could remove it 3 months after rotating, when
> first logs would be 6 months old.
>
> As we already told you, rotate daily and remove old logs after 92 days.
> and use logrotate config.
>
> --
> Matus UHLAR - fantomas, uh...@fantomas.sk ; http://www.fantomas.sk/
> Warning: I wish NOT to receive e-mail advertising to this address.
> Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.
> Linux - It's now safe to turn on your computer.
> Linux - Teraz mozete pocitac bez obav zapnut.
> ___
> squid-users mailing list
> squid-users@lists.squid-cache.org
> http://lists.squid-cache.org/listinfo/squid-users
>
>
___
squid-users mailing list
squid-users@lists.squid-cache.org
http://lists.squid-cache.org/listinfo/squid-users


Re: [squid-users] Logrotate question

2022-06-16 Thread ngtech1ltd
Since this one is from yum install it’s very simple to just change the config 
files of squid and logrotate.
 
If you need more assistance let me know.
 
Eliezer
 
From: robert k Wild  
Sent: Thursday, 16 June 2022 14:52
To: Eliezer Croitoru 
Cc: Squid Users 
Subject: Re: [squid-users] Logrotate question
 
Self compiled from source with others ie
 
Squidclamav
Cicap
Cicap modules
 
And clamav but did this one via yum install
 
 
On Thu, 16 Jun 2022, 12:27 , mailto:ngtech1...@gmail.com> > wrote:
How did you installed squid on CentOS 7?
>From my packages or the OS default or self compiled or another source?
 
Eliezer
 
From: robert k Wild mailto:robertkw...@gmail.com> > 
Sent: Thursday, 16 June 2022 14:05
To: Eliezer Croitoru mailto:ngtech1...@gmail.com> >
Cc: Squid Users mailto:squid-users@lists.squid-cache.org> >
Subject: Re: [squid-users] Logrotate question
 
Oops sorry you did say that, sorry I didn't see that at first
 
On Thu, 16 Jun 2022, 12:04 robert k Wild, mailto:robertkw...@gmail.com> > wrote:
I imagine Eliezer that's what I need to put in logrotate.conf file
 
On Thu, 16 Jun 2022, 12:01 , mailto:ngtech1...@gmail.com> > wrote:
Oops,
 
The next is the file: /etc/logrotate.d/squid
##START
/var/log/squid/*.log {
weekly
rotate 5
compress
notifempty
missingok
nocreate
sharedscripts
postrotate
  # Asks squid to reopen its logs. (logfile_rotate 0 is set in squid.conf)
  # errors redirected to make it silent if squid is not running
  /usr/sbin/squid -k rotate 2>/dev/null
  # Wait a little to allow Squid to catch up before the logs is compressed
  sleep 1
endscript
}
##END
 
So you need to change the rotate to 92+ and also change the squid number of 
logs to the same number.
 
Let me know if you it’s helpful.
 
Eliezer
 
From: ngtech1...@gmail.com <mailto:ngtech1...@gmail.com>  mailto:ngtech1...@gmail.com> > 
Sent: Thursday, 16 June 2022 14:00
To: 'robert k Wild' mailto:robertkw...@gmail.com> >; 
'Squid Users' mailto:squid-users@lists.squid-cache.org> >
Subject: RE: [squid-users] Logrotate question
 
Hey Rob,
 
The next is the file:
 
 
From: squid-users mailto:squid-users-boun...@lists.squid-cache.org> > On Behalf Of robert k Wild
Sent: Thursday, 16 June 2022 13:27
To: Squid Users mailto:squid-users@lists.squid-cache.org> >
Subject: Re: [squid-users] Logrotate question
 
Cool, so I will rotate daily and delete after 91 days, thanks guys
 
On Thu, 16 Jun 2022, 11:14 Matus UHLAR - fantomas, mailto:uh...@fantomas.sk> > wrote:
On 16.06.22 10:54, robert k Wild wrote:
>Basically I want to keep logs for 3 months then rotate so it overwrites
>them with another 3 months, if that makes sense

in fact, it does not.

I guess you are supposed to keep 3 months of logs, which mean, you always 
need to have 3 months of logs available.

Each day, you can delete log files over 3 months old.

If you rotated lof once in 3 months, you would have single file with 3 
months of logs in it, and could remove it 3 months after rotating, when 
first logs would be 6 months old.

As we already told you, rotate daily and remove old logs after 92 days.
and use logrotate config.

-- 
Matus UHLAR - fantomas, uh...@fantomas.sk <mailto:uh...@fantomas.sk>  ; 
http://www.fantomas.sk/
Warning: I wish NOT to receive e-mail advertising to this address.
Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.
Linux - It's now safe to turn on your computer.
Linux - Teraz mozete pocitac bez obav zapnut.
___
squid-users mailing list
squid-users@lists.squid-cache.org <mailto:squid-users@lists.squid-cache.org> 
http://lists.squid-cache.org/listinfo/squid-users
___
squid-users mailing list
squid-users@lists.squid-cache.org
http://lists.squid-cache.org/listinfo/squid-users


Re: [squid-users] Logrotate question

2022-06-16 Thread robert k Wild
Self compiled from source with others ie

Squidclamav
Cicap
Cicap modules

And clamav but did this one via yum install


On Thu, 16 Jun 2022, 12:27 ,  wrote:

> How did you installed squid on CentOS 7?
>
> From my packages or the OS default or self compiled or another source?
>
>
>
> Eliezer
>
>
>
> *From:* robert k Wild 
> *Sent:* Thursday, 16 June 2022 14:05
> *To:* Eliezer Croitoru 
> *Cc:* Squid Users 
> *Subject:* Re: [squid-users] Logrotate question
>
>
>
> Oops sorry you did say that, sorry I didn't see that at first
>
>
>
> On Thu, 16 Jun 2022, 12:04 robert k Wild,  wrote:
>
> I imagine Eliezer that's what I need to put in logrotate.conf file
>
>
>
> On Thu, 16 Jun 2022, 12:01 ,  wrote:
>
> Oops,
>
>
>
> The next is the file: /etc/logrotate.d/squid
>
> ##START
>
> /var/log/squid/*.log {
>
> weekly
>
> rotate 5
>
> compress
>
> notifempty
>
> missingok
>
> nocreate
>
> sharedscripts
>
> postrotate
>
>   # Asks squid to reopen its logs. (logfile_rotate 0 is set in
> squid.conf)
>
>   # errors redirected to make it silent if squid is not running
>
>   /usr/sbin/squid -k rotate 2>/dev/null
>
>   # Wait a little to allow Squid to catch up before the logs is
> compressed
>
>   sleep 1
>
> endscript
>
> }
>
> ##END
>
>
>
> So you need to change the rotate to 92+ and also change the squid number
> of logs to the same number.
>
>
>
> Let me know if you it’s helpful.
>
>
>
> Eliezer
>
>
>
> *From:* ngtech1...@gmail.com 
> *Sent:* Thursday, 16 June 2022 14:00
> *To:* 'robert k Wild' ; 'Squid Users' <
> squid-users@lists.squid-cache.org>
> *Subject:* RE: [squid-users] Logrotate question
>
>
>
> Hey Rob,
>
>
>
> The next is the file:
>
>
>
>
>
> *From:* squid-users  *On
> Behalf Of *robert k Wild
> *Sent:* Thursday, 16 June 2022 13:27
> *To:* Squid Users 
> *Subject:* Re: [squid-users] Logrotate question
>
>
>
> Cool, so I will rotate daily and delete after 91 days, thanks guys
>
>
>
> On Thu, 16 Jun 2022, 11:14 Matus UHLAR - fantomas, 
> wrote:
>
> On 16.06.22 10:54, robert k Wild wrote:
> >Basically I want to keep logs for 3 months then rotate so it overwrites
> >them with another 3 months, if that makes sense
>
> in fact, it does not.
>
> I guess you are supposed to keep 3 months of logs, which mean, you always
> need to have 3 months of logs available.
>
> Each day, you can delete log files over 3 months old.
>
> If you rotated lof once in 3 months, you would have single file with 3
> months of logs in it, and could remove it 3 months after rotating, when
> first logs would be 6 months old.
>
> As we already told you, rotate daily and remove old logs after 92 days.
> and use logrotate config.
>
> --
> Matus UHLAR - fantomas, uh...@fantomas.sk ; http://www.fantomas.sk/
> Warning: I wish NOT to receive e-mail advertising to this address.
> Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.
> Linux - It's now safe to turn on your computer.
> Linux - Teraz mozete pocitac bez obav zapnut.
> ___
> squid-users mailing list
> squid-users@lists.squid-cache.org
> http://lists.squid-cache.org/listinfo/squid-users
>
>
___
squid-users mailing list
squid-users@lists.squid-cache.org
http://lists.squid-cache.org/listinfo/squid-users


Re: [squid-users] Logrotate question

2022-06-16 Thread ngtech1ltd
How did you installed squid on CentOS 7?
>From my packages or the OS default or self compiled or another source?
 
Eliezer
 
From: robert k Wild  
Sent: Thursday, 16 June 2022 14:05
To: Eliezer Croitoru 
Cc: Squid Users 
Subject: Re: [squid-users] Logrotate question
 
Oops sorry you did say that, sorry I didn't see that at first
 
On Thu, 16 Jun 2022, 12:04 robert k Wild, mailto:robertkw...@gmail.com> > wrote:
I imagine Eliezer that's what I need to put in logrotate.conf file
 
On Thu, 16 Jun 2022, 12:01 , mailto:ngtech1...@gmail.com> > wrote:
Oops,
 
The next is the file: /etc/logrotate.d/squid
##START
/var/log/squid/*.log {
weekly
rotate 5
compress
notifempty
missingok
nocreate
sharedscripts
postrotate
  # Asks squid to reopen its logs. (logfile_rotate 0 is set in squid.conf)
  # errors redirected to make it silent if squid is not running
  /usr/sbin/squid -k rotate 2>/dev/null
  # Wait a little to allow Squid to catch up before the logs is compressed
  sleep 1
endscript
}
##END
 
So you need to change the rotate to 92+ and also change the squid number of 
logs to the same number.
 
Let me know if you it’s helpful.
 
Eliezer
 
From: ngtech1...@gmail.com <mailto:ngtech1...@gmail.com>  mailto:ngtech1...@gmail.com> > 
Sent: Thursday, 16 June 2022 14:00
To: 'robert k Wild' mailto:robertkw...@gmail.com> >; 
'Squid Users' mailto:squid-users@lists.squid-cache.org> >
Subject: RE: [squid-users] Logrotate question
 
Hey Rob,
 
The next is the file:
 
 
From: squid-users mailto:squid-users-boun...@lists.squid-cache.org> > On Behalf Of robert k Wild
Sent: Thursday, 16 June 2022 13:27
To: Squid Users mailto:squid-users@lists.squid-cache.org> >
Subject: Re: [squid-users] Logrotate question
 
Cool, so I will rotate daily and delete after 91 days, thanks guys
 
On Thu, 16 Jun 2022, 11:14 Matus UHLAR - fantomas, mailto:uh...@fantomas.sk> > wrote:
On 16.06.22 10:54, robert k Wild wrote:
>Basically I want to keep logs for 3 months then rotate so it overwrites
>them with another 3 months, if that makes sense

in fact, it does not.

I guess you are supposed to keep 3 months of logs, which mean, you always 
need to have 3 months of logs available.

Each day, you can delete log files over 3 months old.

If you rotated lof once in 3 months, you would have single file with 3 
months of logs in it, and could remove it 3 months after rotating, when 
first logs would be 6 months old.

As we already told you, rotate daily and remove old logs after 92 days.
and use logrotate config.

-- 
Matus UHLAR - fantomas, uh...@fantomas.sk <mailto:uh...@fantomas.sk>  ; 
http://www.fantomas.sk/
Warning: I wish NOT to receive e-mail advertising to this address.
Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.
Linux - It's now safe to turn on your computer.
Linux - Teraz mozete pocitac bez obav zapnut.
___
squid-users mailing list
squid-users@lists.squid-cache.org <mailto:squid-users@lists.squid-cache.org> 
http://lists.squid-cache.org/listinfo/squid-users
___
squid-users mailing list
squid-users@lists.squid-cache.org
http://lists.squid-cache.org/listinfo/squid-users


Re: [squid-users] Logrotate question

2022-06-16 Thread robert k Wild
Oops sorry you did say that, sorry I didn't see that at first

On Thu, 16 Jun 2022, 12:04 robert k Wild,  wrote:

> I imagine Eliezer that's what I need to put in logrotate.conf file
>
> On Thu, 16 Jun 2022, 12:01 ,  wrote:
>
>> Oops,
>>
>>
>>
>> The next is the file: /etc/logrotate.d/squid
>>
>> ##START
>>
>> /var/log/squid/*.log {
>>
>> weekly
>>
>> rotate 5
>>
>> compress
>>
>> notifempty
>>
>> missingok
>>
>> nocreate
>>
>> sharedscripts
>>
>> postrotate
>>
>>   # Asks squid to reopen its logs. (logfile_rotate 0 is set in
>> squid.conf)
>>
>>   # errors redirected to make it silent if squid is not running
>>
>>   /usr/sbin/squid -k rotate 2>/dev/null
>>
>>   # Wait a little to allow Squid to catch up before the logs is
>> compressed
>>
>>   sleep 1
>>
>> endscript
>>
>> }
>>
>> ##END
>>
>>
>>
>> So you need to change the rotate to 92+ and also change the squid number
>> of logs to the same number.
>>
>>
>>
>> Let me know if you it’s helpful.
>>
>>
>>
>> Eliezer
>>
>>
>>
>> *From:* ngtech1...@gmail.com 
>> *Sent:* Thursday, 16 June 2022 14:00
>> *To:* 'robert k Wild' ; 'Squid Users' <
>> squid-users@lists.squid-cache.org>
>> *Subject:* RE: [squid-users] Logrotate question
>>
>>
>>
>> Hey Rob,
>>
>>
>>
>> The next is the file:
>>
>>
>>
>>
>>
>> *From:* squid-users  *On
>> Behalf Of *robert k Wild
>> *Sent:* Thursday, 16 June 2022 13:27
>> *To:* Squid Users 
>> *Subject:* Re: [squid-users] Logrotate question
>>
>>
>>
>> Cool, so I will rotate daily and delete after 91 days, thanks guys
>>
>>
>>
>> On Thu, 16 Jun 2022, 11:14 Matus UHLAR - fantomas, 
>> wrote:
>>
>> On 16.06.22 10:54, robert k Wild wrote:
>> >Basically I want to keep logs for 3 months then rotate so it overwrites
>> >them with another 3 months, if that makes sense
>>
>> in fact, it does not.
>>
>> I guess you are supposed to keep 3 months of logs, which mean, you always
>> need to have 3 months of logs available.
>>
>> Each day, you can delete log files over 3 months old.
>>
>> If you rotated lof once in 3 months, you would have single file with 3
>> months of logs in it, and could remove it 3 months after rotating, when
>> first logs would be 6 months old.
>>
>> As we already told you, rotate daily and remove old logs after 92 days.
>> and use logrotate config.
>>
>> --
>> Matus UHLAR - fantomas, uh...@fantomas.sk ; http://www.fantomas.sk/
>> Warning: I wish NOT to receive e-mail advertising to this address.
>> Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.
>> Linux - It's now safe to turn on your computer.
>> Linux - Teraz mozete pocitac bez obav zapnut.
>> ___
>> squid-users mailing list
>> squid-users@lists.squid-cache.org
>> http://lists.squid-cache.org/listinfo/squid-users
>>
>>
___
squid-users mailing list
squid-users@lists.squid-cache.org
http://lists.squid-cache.org/listinfo/squid-users


Re: [squid-users] Logrotate question

2022-06-16 Thread robert k Wild
I imagine Eliezer that's what I need to put in logrotate.conf file

On Thu, 16 Jun 2022, 12:01 ,  wrote:

> Oops,
>
>
>
> The next is the file: /etc/logrotate.d/squid
>
> ##START
>
> /var/log/squid/*.log {
>
> weekly
>
> rotate 5
>
> compress
>
> notifempty
>
> missingok
>
> nocreate
>
> sharedscripts
>
> postrotate
>
>   # Asks squid to reopen its logs. (logfile_rotate 0 is set in
> squid.conf)
>
>   # errors redirected to make it silent if squid is not running
>
>   /usr/sbin/squid -k rotate 2>/dev/null
>
>   # Wait a little to allow Squid to catch up before the logs is
> compressed
>
>   sleep 1
>
> endscript
>
> }
>
> ##END
>
>
>
> So you need to change the rotate to 92+ and also change the squid number
> of logs to the same number.
>
>
>
> Let me know if you it’s helpful.
>
>
>
> Eliezer
>
>
>
> *From:* ngtech1...@gmail.com 
> *Sent:* Thursday, 16 June 2022 14:00
> *To:* 'robert k Wild' ; 'Squid Users' <
> squid-users@lists.squid-cache.org>
> *Subject:* RE: [squid-users] Logrotate question
>
>
>
> Hey Rob,
>
>
>
> The next is the file:
>
>
>
>
>
> *From:* squid-users  *On
> Behalf Of *robert k Wild
> *Sent:* Thursday, 16 June 2022 13:27
> *To:* Squid Users 
> *Subject:* Re: [squid-users] Logrotate question
>
>
>
> Cool, so I will rotate daily and delete after 91 days, thanks guys
>
>
>
> On Thu, 16 Jun 2022, 11:14 Matus UHLAR - fantomas, 
> wrote:
>
> On 16.06.22 10:54, robert k Wild wrote:
> >Basically I want to keep logs for 3 months then rotate so it overwrites
> >them with another 3 months, if that makes sense
>
> in fact, it does not.
>
> I guess you are supposed to keep 3 months of logs, which mean, you always
> need to have 3 months of logs available.
>
> Each day, you can delete log files over 3 months old.
>
> If you rotated lof once in 3 months, you would have single file with 3
> months of logs in it, and could remove it 3 months after rotating, when
> first logs would be 6 months old.
>
> As we already told you, rotate daily and remove old logs after 92 days.
> and use logrotate config.
>
> --
> Matus UHLAR - fantomas, uh...@fantomas.sk ; http://www.fantomas.sk/
> Warning: I wish NOT to receive e-mail advertising to this address.
> Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.
> Linux - It's now safe to turn on your computer.
> Linux - Teraz mozete pocitac bez obav zapnut.
> ___
> squid-users mailing list
> squid-users@lists.squid-cache.org
> http://lists.squid-cache.org/listinfo/squid-users
>
>
___
squid-users mailing list
squid-users@lists.squid-cache.org
http://lists.squid-cache.org/listinfo/squid-users


Re: [squid-users] Logrotate question

2022-06-16 Thread ngtech1ltd
Oops,
 
The next is the file: /etc/logrotate.d/squid
##START
/var/log/squid/*.log {
weekly
rotate 5
compress
notifempty
missingok
nocreate
sharedscripts
postrotate
  # Asks squid to reopen its logs. (logfile_rotate 0 is set in squid.conf)
  # errors redirected to make it silent if squid is not running
  /usr/sbin/squid -k rotate 2>/dev/null
  # Wait a little to allow Squid to catch up before the logs is compressed
  sleep 1
endscript
}
##END
 
So you need to change the rotate to 92+ and also change the squid number of 
logs to the same number.
 
Let me know if you it’s helpful.
 
Eliezer
 
From: ngtech1...@gmail.com  
Sent: Thursday, 16 June 2022 14:00
To: 'robert k Wild' ; 'Squid Users' 

Subject: RE: [squid-users] Logrotate question
 
Hey Rob,
 
The next is the file:
 
 
From: squid-users mailto:squid-users-boun...@lists.squid-cache.org> > On Behalf Of robert k Wild
Sent: Thursday, 16 June 2022 13:27
To: Squid Users mailto:squid-users@lists.squid-cache.org> >
Subject: Re: [squid-users] Logrotate question
 
Cool, so I will rotate daily and delete after 91 days, thanks guys
 
On Thu, 16 Jun 2022, 11:14 Matus UHLAR - fantomas, mailto:uh...@fantomas.sk> > wrote:
On 16.06.22 10:54, robert k Wild wrote:
>Basically I want to keep logs for 3 months then rotate so it overwrites
>them with another 3 months, if that makes sense

in fact, it does not.

I guess you are supposed to keep 3 months of logs, which mean, you always 
need to have 3 months of logs available.

Each day, you can delete log files over 3 months old.

If you rotated lof once in 3 months, you would have single file with 3 
months of logs in it, and could remove it 3 months after rotating, when 
first logs would be 6 months old.

As we already told you, rotate daily and remove old logs after 92 days.
and use logrotate config.

-- 
Matus UHLAR - fantomas, uh...@fantomas.sk <mailto:uh...@fantomas.sk>  ; 
http://www.fantomas.sk/
Warning: I wish NOT to receive e-mail advertising to this address.
Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.
Linux - It's now safe to turn on your computer.
Linux - Teraz mozete pocitac bez obav zapnut.
___
squid-users mailing list
squid-users@lists.squid-cache.org <mailto:squid-users@lists.squid-cache.org> 
http://lists.squid-cache.org/listinfo/squid-users
___
squid-users mailing list
squid-users@lists.squid-cache.org
http://lists.squid-cache.org/listinfo/squid-users


Re: [squid-users] Logrotate question

2022-06-16 Thread ngtech1ltd
Hey Rob,
 
The next is the file:
 
 
From: squid-users  On Behalf Of 
robert k Wild
Sent: Thursday, 16 June 2022 13:27
To: Squid Users 
Subject: Re: [squid-users] Logrotate question
 
Cool, so I will rotate daily and delete after 91 days, thanks guys
 
On Thu, 16 Jun 2022, 11:14 Matus UHLAR - fantomas, mailto:uh...@fantomas.sk> > wrote:
On 16.06.22 10:54, robert k Wild wrote:
>Basically I want to keep logs for 3 months then rotate so it overwrites
>them with another 3 months, if that makes sense

in fact, it does not.

I guess you are supposed to keep 3 months of logs, which mean, you always 
need to have 3 months of logs available.

Each day, you can delete log files over 3 months old.

If you rotated lof once in 3 months, you would have single file with 3 
months of logs in it, and could remove it 3 months after rotating, when 
first logs would be 6 months old.

As we already told you, rotate daily and remove old logs after 92 days.
and use logrotate config.

-- 
Matus UHLAR - fantomas, uh...@fantomas.sk <mailto:uh...@fantomas.sk>  ; 
http://www.fantomas.sk/
Warning: I wish NOT to receive e-mail advertising to this address.
Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.
Linux - It's now safe to turn on your computer.
Linux - Teraz mozete pocitac bez obav zapnut.
___
squid-users mailing list
squid-users@lists.squid-cache.org <mailto:squid-users@lists.squid-cache.org> 
http://lists.squid-cache.org/listinfo/squid-users
___
squid-users mailing list
squid-users@lists.squid-cache.org
http://lists.squid-cache.org/listinfo/squid-users


Re: [squid-users] Logrotate question

2022-06-16 Thread robert k Wild
Ok sorry as normally 3 months is 90 days and I just added a 1 to it, but I
get what you mean if months have 31 I should really do 93 as I want to give
it extra room incase

On Thu, 16 Jun 2022, 11:41 Antony Stone, 
wrote:

> On Thursday 16 June 2022 at 11:26:37, robert k Wild wrote:
>
> > Cool, so I will rotate daily and delete after 91 days, thanks guys
>
> Why did you change the recommended 92 days into 91?
>
> Consider June, July and August:
>
> June has 30 days
> July has 31 days
> August has 31 days
>
> So, on September 1st, June 1st is 92 days ago, and you can delete the logs
> for
> May 31st, which are older than 92 days.
>
> If you deleted older than 91 days, you would be deleting June 1st on
> September
> 1st, and one day this might be significant to someone.
>
>
> Antony.
>
> > On Thu, 16 Jun 2022, 11:14 Matus UHLAR - fantomas wrote:
> > > On 16.06.22 10:54, robert k Wild wrote:
> > > >Basically I want to keep logs for 3 months then rotate so it
> overwrites
> > > >them with another 3 months, if that makes sense
> > >
> > > in fact, it does not.
> > >
> > > I guess you are supposed to keep 3 months of logs, which mean, you
> always
> > > need to have 3 months of logs available.
> > >
> > > Each day, you can delete log files over 3 months old.
> > >
> > > If you rotated lof once in 3 months, you would have single file with 3
> > > months of logs in it, and could remove it 3 months after rotating, when
> > > first logs would be 6 months old.
> > >
> > > As we already told you, rotate daily and remove old logs after 92 days.
> > > and use logrotate config.
>
> --
> I just got a new mobile phone, and I called it Titanic.  It's already
> syncing.
>
>Please reply to the
> list;
>  please *don't* CC
> me.
> ___
> squid-users mailing list
> squid-users@lists.squid-cache.org
> http://lists.squid-cache.org/listinfo/squid-users
>
___
squid-users mailing list
squid-users@lists.squid-cache.org
http://lists.squid-cache.org/listinfo/squid-users


Re: [squid-users] Logrotate question

2022-06-16 Thread Antony Stone
On Thursday 16 June 2022 at 11:26:37, robert k Wild wrote:

> Cool, so I will rotate daily and delete after 91 days, thanks guys

Why did you change the recommended 92 days into 91?

Consider June, July and August:

June has 30 days
July has 31 days
August has 31 days

So, on September 1st, June 1st is 92 days ago, and you can delete the logs for 
May 31st, which are older than 92 days.

If you deleted older than 91 days, you would be deleting June 1st on September 
1st, and one day this might be significant to someone.


Antony.

> On Thu, 16 Jun 2022, 11:14 Matus UHLAR - fantomas wrote:
> > On 16.06.22 10:54, robert k Wild wrote:
> > >Basically I want to keep logs for 3 months then rotate so it overwrites
> > >them with another 3 months, if that makes sense
> > 
> > in fact, it does not.
> > 
> > I guess you are supposed to keep 3 months of logs, which mean, you always
> > need to have 3 months of logs available.
> > 
> > Each day, you can delete log files over 3 months old.
> > 
> > If you rotated lof once in 3 months, you would have single file with 3
> > months of logs in it, and could remove it 3 months after rotating, when
> > first logs would be 6 months old.
> > 
> > As we already told you, rotate daily and remove old logs after 92 days.
> > and use logrotate config.

-- 
I just got a new mobile phone, and I called it Titanic.  It's already syncing.

   Please reply to the list;
 please *don't* CC me.
___
squid-users mailing list
squid-users@lists.squid-cache.org
http://lists.squid-cache.org/listinfo/squid-users


Re: [squid-users] Logrotate question

2022-06-16 Thread robert k Wild
Cool, so I will rotate daily and delete after 91 days, thanks guys

On Thu, 16 Jun 2022, 11:14 Matus UHLAR - fantomas, 
wrote:

> On 16.06.22 10:54, robert k Wild wrote:
> >Basically I want to keep logs for 3 months then rotate so it overwrites
> >them with another 3 months, if that makes sense
>
> in fact, it does not.
>
> I guess you are supposed to keep 3 months of logs, which mean, you always
> need to have 3 months of logs available.
>
> Each day, you can delete log files over 3 months old.
>
> If you rotated lof once in 3 months, you would have single file with 3
> months of logs in it, and could remove it 3 months after rotating, when
> first logs would be 6 months old.
>
> As we already told you, rotate daily and remove old logs after 92 days.
> and use logrotate config.
>
> --
> Matus UHLAR - fantomas, uh...@fantomas.sk ; http://www.fantomas.sk/
> Warning: I wish NOT to receive e-mail advertising to this address.
> Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.
> Linux - It's now safe to turn on your computer.
> Linux - Teraz mozete pocitac bez obav zapnut.
> ___
> squid-users mailing list
> squid-users@lists.squid-cache.org
> http://lists.squid-cache.org/listinfo/squid-users
>
___
squid-users mailing list
squid-users@lists.squid-cache.org
http://lists.squid-cache.org/listinfo/squid-users


Re: [squid-users] Logrotate question

2022-06-16 Thread Matus UHLAR - fantomas

On 16.06.22 10:54, robert k Wild wrote:

Basically I want to keep logs for 3 months then rotate so it overwrites
them with another 3 months, if that makes sense


in fact, it does not.

I guess you are supposed to keep 3 months of logs, which mean, you always 
need to have 3 months of logs available.


Each day, you can delete log files over 3 months old.

If you rotated lof once in 3 months, you would have single file with 3 
months of logs in it, and could remove it 3 months after rotating, when 
first logs would be 6 months old.


As we already told you, rotate daily and remove old logs after 92 days.
and use logrotate config.

--
Matus UHLAR - fantomas, uh...@fantomas.sk ; http://www.fantomas.sk/
Warning: I wish NOT to receive e-mail advertising to this address.
Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.
Linux - It's now safe to turn on your computer.
Linux - Teraz mozete pocitac bez obav zapnut.
___
squid-users mailing list
squid-users@lists.squid-cache.org
http://lists.squid-cache.org/listinfo/squid-users


Re: [squid-users] Logrotate question

2022-06-16 Thread robert k Wild
Hi Eliezer,

Basically I want to keep logs for 3 months then rotate so it overwrites
them with another 3 months, if that makes sense

On Thu, 16 Jun 2022, 10:39 ,  wrote:

> Hey Rob,
>
>
>
> First there is a difference between rotation and deletion.
>
> If it’s not a loaded system then 3 month is ok but… in most use cases
> it’s better to rotate every day but to delete after 3 month.
>
> You have the choice to compress the files or to leave them in plain text
> but it’s only a choice of resources preservation.
>
>
>
> Let me see, I will look at my CentOS 7 system and will try to find the
> right way to do it.
>
>
>
> Eliezer
>
>
>
> *From:* robert k Wild 
> *Sent:* Thursday, 16 June 2022 11:28
> *To:* Eliezer Croitoru 
> *Cc:* Squid Users 
> *Subject:* Re: [squid-users] Logrotate question
>
>
>
> Thanks Eliezer
>
>
>
> I have centos 7 and I want it to rotate every 3 months as we need to keep
> logs for every 3 months.
>
>
>
> Thanks,
>
> Rob
>
>
>
> On Thu, 16 Jun 2022, 08:11 ,  wrote:
>
> Rob,
>
>
>
> It will be different how you implement and use logrotate manually or with
> the logrotate tools.
>
> What OS are you using?
>
>
>
> Eliezer
>
>
>
> *From:* squid-users  *On
> Behalf Of *robert k Wild
> *Sent:* Wednesday, 15 June 2022 20:19
> *To:* Squid Users 
> *Subject:* [squid-users] Logrotate question
>
>
>
> Hi all,
>
>
>
> ATM to clear the logs, I do this in crontab, every 3 months
>
>
>
> 0 0 1 */3 * echo "" > /usr/local/squid/var/logs/access.log and do the same
> for cache log
>
>
>
> It works but I want to really use log rotate ie
>
>
>
> 0 0 1 */3 * /usr/local/squid/sbin/squid -k rotate
>
>
>
> I hear log rotate keeps 10 files by default so does that mean I will have
> 10 access logs etc and also will it keep the file the same ie won't change
> the size or compress it to save space
>
>
>
> Thanks,
>
> Rob
>
> ___
> squid-users mailing list
> squid-users@lists.squid-cache.org
> http://lists.squid-cache.org/listinfo/squid-users
>
>
___
squid-users mailing list
squid-users@lists.squid-cache.org
http://lists.squid-cache.org/listinfo/squid-users


Re: [squid-users] Logrotate question

2022-06-16 Thread ngtech1ltd
You should combine them both.
I am checking this for you right now…
 
Eliezer
 
From: squid-users  On Behalf Of 
robert k Wild
Sent: Thursday, 16 June 2022 12:32
To: Squid Users 
Subject: Re: [squid-users] Logrotate question
 
Cool, Thanks all, il try the logrotate program instead of using squids one
 
Thanks guys :)
 
On Thu, 16 Jun 2022, 10:26 Matus UHLAR - fantomas, mailto:uh...@fantomas.sk> > wrote:
On 16.06.22 10:23, robert k Wild wrote:
>So I can use the package logrotate instead of the squid one

squid packages in debian comes configured for rotating logs with logrotate.
- logfile_rotate is set to 0
- logrotate config file tells when/how to rotate

perhaps it's the same with centos.


>On Thu, 16 Jun 2022, 10:22 Matus UHLAR - fantomas, <mailto:uh...@fantomas.sk> >
>wrote:
>
>> On 16.06.22 09:53, robert k Wild wrote:
>> >All I know is I need to keep a record of up to 3 months, worth of logs,
>> due
>> >to gdpr, how would you say I go about this
>>
>> keeping 3 months of log is very different from rotating each 3 months.
>> configure logrotate to rotate daily and keep 92 days worth of logs.
>>
>> I believe centos squid package comes with logrotate configured, should be
>> in
>> /etc/logrotate.d/squid


-- 
Matus UHLAR - fantomas, uh...@fantomas.sk <mailto:uh...@fantomas.sk>  ; 
http://www.fantomas.sk/
Warning: I wish NOT to receive e-mail advertising to this address.
Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.
My mind is like a steel trap - rusty and illegal in 37 states.
___
squid-users mailing list
squid-users@lists.squid-cache.org <mailto:squid-users@lists.squid-cache.org> 
http://lists.squid-cache.org/listinfo/squid-users
___
squid-users mailing list
squid-users@lists.squid-cache.org
http://lists.squid-cache.org/listinfo/squid-users


Re: [squid-users] Logrotate question

2022-06-16 Thread ngtech1ltd
Hey Rob,
 
First there is a difference between rotation and deletion.
If it’s not a loaded system then 3 month is ok but… in most use cases it’s 
better to rotate every day but to delete after 3 month.
You have the choice to compress the files or to leave them in plain text but 
it’s only a choice of resources preservation.
 
Let me see, I will look at my CentOS 7 system and will try to find the right 
way to do it.
 
Eliezer
 
From: robert k Wild  
Sent: Thursday, 16 June 2022 11:28
To: Eliezer Croitoru 
Cc: Squid Users 
Subject: Re: [squid-users] Logrotate question
 
Thanks Eliezer
 
I have centos 7 and I want it to rotate every 3 months as we need to keep logs 
for every 3 months.
 
Thanks,
Rob
 
On Thu, 16 Jun 2022, 08:11 , mailto:ngtech1...@gmail.com> > wrote:
Rob,
 
It will be different how you implement and use logrotate manually or with the 
logrotate tools.
What OS are you using?
 
Eliezer
 
From: squid-users mailto:squid-users-boun...@lists.squid-cache.org> > On Behalf Of robert k Wild
Sent: Wednesday, 15 June 2022 20:19
To: Squid Users mailto:squid-users@lists.squid-cache.org> >
Subject: [squid-users] Logrotate question
 
Hi all,
 
ATM to clear the logs, I do this in crontab, every 3 months
 
0 0 1 */3 * echo "" > /usr/local/squid/var/logs/access.log and do the same for 
cache log
 
It works but I want to really use log rotate ie
 
0 0 1 */3 * /usr/local/squid/sbin/squid -k rotate
 
I hear log rotate keeps 10 files by default so does that mean I will have 10 
access logs etc and also will it keep the file the same ie won't change the 
size or compress it to save space
 
Thanks,
Rob
___
squid-users mailing list
squid-users@lists.squid-cache.org <mailto:squid-users@lists.squid-cache.org> 
http://lists.squid-cache.org/listinfo/squid-users
___
squid-users mailing list
squid-users@lists.squid-cache.org
http://lists.squid-cache.org/listinfo/squid-users


Re: [squid-users] Logrotate question

2022-06-16 Thread robert k Wild
Cool, Thanks all, il try the logrotate program instead of using squids one

Thanks guys :)

On Thu, 16 Jun 2022, 10:26 Matus UHLAR - fantomas, 
wrote:

> On 16.06.22 10:23, robert k Wild wrote:
> >So I can use the package logrotate instead of the squid one
>
> squid packages in debian comes configured for rotating logs with logrotate.
> - logfile_rotate is set to 0
> - logrotate config file tells when/how to rotate
>
> perhaps it's the same with centos.
>
>
> >On Thu, 16 Jun 2022, 10:22 Matus UHLAR - fantomas, 
> >wrote:
> >
> >> On 16.06.22 09:53, robert k Wild wrote:
> >> >All I know is I need to keep a record of up to 3 months, worth of logs,
> >> due
> >> >to gdpr, how would you say I go about this
> >>
> >> keeping 3 months of log is very different from rotating each 3 months.
> >> configure logrotate to rotate daily and keep 92 days worth of logs.
> >>
> >> I believe centos squid package comes with logrotate configured, should
> be
> >> in
> >> /etc/logrotate.d/squid
>
>
> --
> Matus UHLAR - fantomas, uh...@fantomas.sk ; http://www.fantomas.sk/
> Warning: I wish NOT to receive e-mail advertising to this address.
> Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.
> My mind is like a steel trap - rusty and illegal in 37 states.
> ___
> squid-users mailing list
> squid-users@lists.squid-cache.org
> http://lists.squid-cache.org/listinfo/squid-users
>
___
squid-users mailing list
squid-users@lists.squid-cache.org
http://lists.squid-cache.org/listinfo/squid-users


Re: [squid-users] Logrotate question

2022-06-16 Thread Antony Stone
On Thursday 16 June 2022 at 09:53:02, robert k Wild wrote:

> Hi Antony,
> 
> All I know is I need to keep a record of up to 3 months, worth of logs, due
> to gdpr, how would you say I go about this

Here's the standard logrotate file for Squid3 which is installed on Debian (I 
doubt that CentOS should be significantly different):

-
/var/log/squid/*.log {
daily
compress
delaycompress
rotate 2
missingok
nocreate
sharedscripts
prerotate
test ! -x /usr/sbin/sarg-reports || /usr/sbin/sarg-reports 
daily
endscript
postrotate
test ! -e /var/run/squid.pid || test ! -x /usr/sbin/squid || 
/usr/sbin/squid -k rotate
endscript
}
-

I suggest modifying this for your needs to:

-
/var/log/squid/*.log {
monthly
rotate 4
missingok
nocreate
sharedscripts
prerotate
test ! -x /usr/sbin/sarg-reports || /usr/sbin/sarg-reports 
daily
endscript
postrotate
test ! -e /var/run/squid.pid || test ! -x /usr/sbin/squid || 
/usr/sbin/squid -k rotate
endscript
}
-

Regards,


Antony.

-- 
Your work is both good and original.  Unfortunately the parts that are good 
aren't original, and the parts that are original aren't good.

 - Samuel Johnson

   Please reply to the list;
 please *don't* CC me.
___
squid-users mailing list
squid-users@lists.squid-cache.org
http://lists.squid-cache.org/listinfo/squid-users


Re: [squid-users] Logrotate question

2022-06-16 Thread Matus UHLAR - fantomas

On 16.06.22 10:23, robert k Wild wrote:

So I can use the package logrotate instead of the squid one


squid packages in debian comes configured for rotating logs with logrotate.
- logfile_rotate is set to 0
- logrotate config file tells when/how to rotate

perhaps it's the same with centos.



On Thu, 16 Jun 2022, 10:22 Matus UHLAR - fantomas, 
wrote:


On 16.06.22 09:53, robert k Wild wrote:
>All I know is I need to keep a record of up to 3 months, worth of logs,
due
>to gdpr, how would you say I go about this

keeping 3 months of log is very different from rotating each 3 months.
configure logrotate to rotate daily and keep 92 days worth of logs.

I believe centos squid package comes with logrotate configured, should be
in
/etc/logrotate.d/squid



--
Matus UHLAR - fantomas, uh...@fantomas.sk ; http://www.fantomas.sk/
Warning: I wish NOT to receive e-mail advertising to this address.
Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.
My mind is like a steel trap - rusty and illegal in 37 states.
___
squid-users mailing list
squid-users@lists.squid-cache.org
http://lists.squid-cache.org/listinfo/squid-users


Re: [squid-users] Logrotate question

2022-06-16 Thread robert k Wild
So I can use the package logrotate instead of the squid one

On Thu, 16 Jun 2022, 10:22 Matus UHLAR - fantomas, 
wrote:

> On 16.06.22 09:53, robert k Wild wrote:
> >All I know is I need to keep a record of up to 3 months, worth of logs,
> due
> >to gdpr, how would you say I go about this
>
> keeping 3 months of log is very different from rotating each 3 months.
> configure logrotate to rotate daily and keep 92 days worth of logs.
>
> I believe centos squid package comes with logrotate configured, should be
> in
> /etc/logrotate.d/squid
>
> --
> Matus UHLAR - fantomas, uh...@fantomas.sk ; http://www.fantomas.sk/
> Warning: I wish NOT to receive e-mail advertising to this address.
> Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.
> I feel like I'm diagonally parked in a parallel universe.
> ___
> squid-users mailing list
> squid-users@lists.squid-cache.org
> http://lists.squid-cache.org/listinfo/squid-users
>
___
squid-users mailing list
squid-users@lists.squid-cache.org
http://lists.squid-cache.org/listinfo/squid-users


Re: [squid-users] Logrotate question

2022-06-16 Thread Matus UHLAR - fantomas

On 16.06.22 09:53, robert k Wild wrote:

All I know is I need to keep a record of up to 3 months, worth of logs, due
to gdpr, how would you say I go about this


keeping 3 months of log is very different from rotating each 3 months.
configure logrotate to rotate daily and keep 92 days worth of logs.

I believe centos squid package comes with logrotate configured, should be in 
/etc/logrotate.d/squid


--
Matus UHLAR - fantomas, uh...@fantomas.sk ; http://www.fantomas.sk/
Warning: I wish NOT to receive e-mail advertising to this address.
Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.
I feel like I'm diagonally parked in a parallel universe.
___
squid-users mailing list
squid-users@lists.squid-cache.org
http://lists.squid-cache.org/listinfo/squid-users


Re: [squid-users] Logrotate question

2022-06-16 Thread robert k Wild
Hi Antony,

All I know is I need to keep a record of up to 3 months, worth of logs, due
to gdpr, how would you say I go about this

Thanks,
Rob

On Thu, 16 Jun 2022, 09:49 Antony Stone, 
wrote:

> On Thursday 16 June 2022 at 09:27:32, robert k Wild wrote:
>
> > Thanks Eliezer
> >
> > I have centos 7 and I want it to rotate every 3 months as we need to keep
> > logs for every 3 months.
>
> Do you really mean you "need to keep logs for every 3 months"?
>
> Or do you mean that you need to keep "the most recent 3 months' logs"?
>
> I would recommend that you rotate every month, and keep 4 months' logs.
>
> Firstly, there's no point in letting indivdual log files grow too large,
> and
> secondly, you then know that at all times you have the current month's
> logs,
> plus the previous 3 months, until the fourth one gets deleted by logrotate.
>
>
> Antony.
>
> > On Thu, 16 Jun 2022, 08:11 ,  wrote:
> > > Rob,
> > >
> > > It will be different how you implement and use logrotate manually or
> with
> > > the logrotate tools.
> > >
> > > What OS are you using?
> > >
> > > Eliezer
> > >
> > > *From:* squid-users  *On
> > > Behalf Of *robert k Wild
> > > *Sent:* Wednesday, 15 June 2022 20:19
> > > *To:* Squid Users 
> > > *Subject:* [squid-users] Logrotate question
> > >
> > > Hi all,
> > >
> > > ATM to clear the logs, I do this in crontab, every 3 months
> > >
> > > 0 0 1 */3 * echo "" > /usr/local/squid/var/logs/access.log and do the
> > > same for cache log
> > >
> > > It works but I want to really use log rotate ie
> > >
> > > 0 0 1 */3 * /usr/local/squid/sbin/squid -k rotate
> > >
> > > I hear log rotate keeps 10 files by default so does that mean I will
> have
> > > 10 access logs etc and also will it keep the file the same ie won't
> > > change the size or compress it to save space
> > >
> > >
> > > Thanks,
> > >
> > > Rob
> > > ___
> > > squid-users mailing list
> > > squid-users@lists.squid-cache.org
> > > http://lists.squid-cache.org/listinfo/squid-users
>
> --
> The next sentence is untrue.
> The previous sentence is also not true.
>
>Please reply to the
> list;
>  please *don't* CC
> me.
> ___
> squid-users mailing list
> squid-users@lists.squid-cache.org
> http://lists.squid-cache.org/listinfo/squid-users
>
___
squid-users mailing list
squid-users@lists.squid-cache.org
http://lists.squid-cache.org/listinfo/squid-users


Re: [squid-users] Logrotate question

2022-06-16 Thread Antony Stone
On Thursday 16 June 2022 at 09:27:32, robert k Wild wrote:

> Thanks Eliezer
> 
> I have centos 7 and I want it to rotate every 3 months as we need to keep
> logs for every 3 months.

Do you really mean you "need to keep logs for every 3 months"?

Or do you mean that you need to keep "the most recent 3 months' logs"?

I would recommend that you rotate every month, and keep 4 months' logs.

Firstly, there's no point in letting indivdual log files grow too large, and 
secondly, you then know that at all times you have the current month's logs, 
plus the previous 3 months, until the fourth one gets deleted by logrotate.


Antony.

> On Thu, 16 Jun 2022, 08:11 ,  wrote:
> > Rob,
> > 
> > It will be different how you implement and use logrotate manually or with
> > the logrotate tools.
> > 
> > What OS are you using?
> > 
> > Eliezer
> > 
> > *From:* squid-users  *On
> > Behalf Of *robert k Wild
> > *Sent:* Wednesday, 15 June 2022 20:19
> > *To:* Squid Users 
> > *Subject:* [squid-users] Logrotate question
> > 
> > Hi all,
> > 
> > ATM to clear the logs, I do this in crontab, every 3 months
> > 
> > 0 0 1 */3 * echo "" > /usr/local/squid/var/logs/access.log and do the
> > same for cache log
> > 
> > It works but I want to really use log rotate ie
> > 
> > 0 0 1 */3 * /usr/local/squid/sbin/squid -k rotate
> > 
> > I hear log rotate keeps 10 files by default so does that mean I will have
> > 10 access logs etc and also will it keep the file the same ie won't
> > change the size or compress it to save space
> > 
> > 
> > Thanks,
> > 
> > Rob
> > ___
> > squid-users mailing list
> > squid-users@lists.squid-cache.org
> > http://lists.squid-cache.org/listinfo/squid-users

-- 
The next sentence is untrue.
The previous sentence is also not true.

   Please reply to the list;
 please *don't* CC me.
___
squid-users mailing list
squid-users@lists.squid-cache.org
http://lists.squid-cache.org/listinfo/squid-users


Re: [squid-users] Logrotate question

2022-06-16 Thread robert k Wild
Thanks Eliezer

I have centos 7 and I want it to rotate every 3 months as we need to keep
logs for every 3 months.

Thanks,
Rob

On Thu, 16 Jun 2022, 08:11 ,  wrote:

> Rob,
>
>
>
> It will be different how you implement and use logrotate manually or with
> the logrotate tools.
>
> What OS are you using?
>
>
>
> Eliezer
>
>
>
> *From:* squid-users  *On
> Behalf Of *robert k Wild
> *Sent:* Wednesday, 15 June 2022 20:19
> *To:* Squid Users 
> *Subject:* [squid-users] Logrotate question
>
>
>
> Hi all,
>
>
>
> ATM to clear the logs, I do this in crontab, every 3 months
>
>
>
> 0 0 1 */3 * echo "" > /usr/local/squid/var/logs/access.log and do the same
> for cache log
>
>
>
> It works but I want to really use log rotate ie
>
>
>
> 0 0 1 */3 * /usr/local/squid/sbin/squid -k rotate
>
>
>
> I hear log rotate keeps 10 files by default so does that mean I will have
> 10 access logs etc and also will it keep the file the same ie won't change
> the size or compress it to save space
>
>
>
> Thanks,
>
> Rob
> ___
> squid-users mailing list
> squid-users@lists.squid-cache.org
> http://lists.squid-cache.org/listinfo/squid-users
>
___
squid-users mailing list
squid-users@lists.squid-cache.org
http://lists.squid-cache.org/listinfo/squid-users


Re: [squid-users] Logrotate question

2022-06-16 Thread ngtech1ltd
Rob,
 
It will be different how you implement and use logrotate manually or with the 
logrotate tools.
What OS are you using?
 
Eliezer
 
From: squid-users  On Behalf Of 
robert k Wild
Sent: Wednesday, 15 June 2022 20:19
To: Squid Users 
Subject: [squid-users] Logrotate question
 
Hi all,
 
ATM to clear the logs, I do this in crontab, every 3 months
 
0 0 1 */3 * echo "" > /usr/local/squid/var/logs/access.log and do the same for 
cache log
 
It works but I want to really use log rotate ie
 
0 0 1 */3 * /usr/local/squid/sbin/squid -k rotate
 
I hear log rotate keeps 10 files by default so does that mean I will have 10 
access logs etc and also will it keep the file the same ie won't change the 
size or compress it to save space
 
Thanks,
Rob
___
squid-users mailing list
squid-users@lists.squid-cache.org
http://lists.squid-cache.org/listinfo/squid-users


[squid-users] Logrotate question

2022-06-15 Thread robert k Wild
Hi all,

ATM to clear the logs, I do this in crontab, every 3 months

0 0 1 */3 * echo "" > /usr/local/squid/var/logs/access.log and do the same
for cache log

It works but I want to really use log rotate ie

0 0 1 */3 * /usr/local/squid/sbin/squid -k rotate

I hear log rotate keeps 10 files by default so does that mean I will have
10 access logs etc and also will it keep the file the same ie won't change
the size or compress it to save space

Thanks,
Rob
___
squid-users mailing list
squid-users@lists.squid-cache.org
http://lists.squid-cache.org/listinfo/squid-users