logo       

Re: Logging Enhydra user access/statistics: msg#00032

java.enhydra.general

Subject: Re: Logging Enhydra user access/statistics

On Thursday 16 January 2003 13:35, Frederic Garzon wrote:
> Darius Katz wrote:
> >
> >Is there a way to automatically split up the Enhydra user
> >access/statistics logging, i.e. every week or every month in order to
> >avoid HUGE log-files?
>
> AFAIK, this is not possible. If you can, wait for Enhydra 5.1 and the
> log4j integration : log4j is much more powerful than the StandardLogger...
> If you can't wait, don't log to a file, but to StdErr, and pipe the
> output of Enhydra either to syslog with logger (if you're under unix),
> or through a script/program like rotatelogs, distributed with apache. It
> handles nicely the job of rotating the logs for you :
>
> $ /usr/sbin/rotatelogs --help
> Usage: /usr/sbin/rotatelogs <logfile> <rotation time in seconds> [offset
> minutes from UTC]
>
> Add this:
>
> TransferLog "|/usr/sbin/rotatelogs /some/where 86400"
>
> to httpd.conf. The generated name will be /some/where.nnnn where nnnn is
> the system time at which the log nominally starts (N.B. this time will
> always be a
> multiple of the rotation time, so you can synchronize cron scripts with
> it). At the end of each rotation time a new log is started.

Hi,

Under Linux (Unix?), you can also use the logrotate package:
For example with Debian, you just have to add an entry in:
/etc/logrotate.d/
to rotate a log file every day or every week.
see also /etc/logrotate.conf

Hope this helps,

--
Mathieu Peltier
INRIA Rhône-Alpes - ObjectWeb Consortium
http://www.inrialpes.fr/ - http://www.objectweb.org/

Counting in binary is just like counting in decimal -- if you are all thumbs.
-- Glaser and Way


<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | FAQ | advertise