You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by Jochen Kächelin <jk...@linux.amsjk.de> on 2002/11/24 01:02:29 UTC
[users@httpd] Compressing logfiles
How can I daily build logfiles files like
access_log-10112002.tgz
error_log-10112002.tgz
agent_log-10112002.tgz
referer_log-10112002.tgz
with rotatelogs?
--
Jochen Kaechelin
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
Re: [users@httpd] Compressing logfiles
Posted by pi...@goldfisch.at.
On Sun, Nov 24, 2002 at 01:02:29AM +0100, Jochen Kächelin wrote:
> How can I daily build logfiles files like
>
> access_log-10112002.tgz
> error_log-10112002.tgz
> agent_log-10112002.tgz
> referer_log-10112002.tgz
>
> with rotatelogs?
>
you can very easily recalculate the trailing numbers : I just put the
perl-code here : (assuming you choose daily rotation : 86400 is the
number you also specified in your rotatelogs-command)
$a=`date +%s`; $a=int($a/86400)*86400
and therefore compress logs in your crontab.
peter
http://www2.goldfisch.at/knowledge/172
--
mag. peter pilsl
IT-Consulting
tel: +43-699-1-3574035
fax: +43-699-4-3574035
pilsl@goldfisch.at
http://www.goldfisch.at
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org