httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ziv Rozenfeld" <zi...@screenpeaks.com>
Subject RE: [users@httpd] Re: apache logs - one per day
Date Wed, 25 Aug 2004 06:27:13 GMT
can you please email me the conolig install file?
ziv_r@screenpeaks.com

-----Original Message-----
From: Hugh Williams [mailto:hughw@soco.agilent.com]
Sent: Tuesday, August 24, 2004 5:07 PM
To: users@httpd.apache.org
Subject: [users@httpd] Re: apache logs - one per day


Ziv Rozenfeld wrote:
> im using apache 2.0.50 on win2k
> i want the apache to create a new access.log file per day.
> what changes should i make in the httpd.conf file at the CustomLog and the Logformat?
> 
> 
> I've tried adding the next line with no success:
> CustomLog "|bin/rotatelogs /logs/access.log 86400" common 
> 
> p.s
> the apache in installed under c:\Program Files\Apache Group\Apache2
> if in possible, i want that each access.log file will contain the date of the day he
was created
> Thanks!

You should probably check out one or another of the many external log
rotation programs.  I use 'cronolog' (http://www.cronolog.org/); it
allows me to rotate logs and retain the old ones in separate files with
almost whatever kind of date labeling you can think of.  Here's what the
conf lines look like:

ErrorLog "|/opt/apache/bin/cronolog /opt/apache/logs/%Y/%m/error_log.%Y%m%d"
CustomLog "|/opt/apache/bin/cronolog /opt/apache/logs/%Y/%m/access_log.%Y%m%d" custom

This saves old logs daily into a directory structure sorted by year,
month and day (which I periodically compress after the fact).

hugh

-- 
 Hugh Williams			"And the time will come when you'll see
 hugh_williams@agilent.com  	 We're all very small
 Agilent Technologies 		 And life flows on within you and without you"
 Santa Rosa 2LS-R				- Beatles
 (707)-577-4941

---------------------------------------------------------------------
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


---------------------------------------------------------------------
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


Mime
View raw message