This is a discussion on apache delayed log write ? within the Linux Web Servers forums, part of the Web Server and Related Forums category; Hi all, I'm wondering if it's possible to delay write of CustomLog directive instead of writting to file ...
|
|||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
|
|||
|
Hi all,
I'm wondering if it's possible to delay write of CustomLog directive instead of writting to file as soon as request is made ? I believe it should be possible to pipe data to external program that will store log in buffer and then write it after a delay, say every 10 seconds but I'm not aware of program that is able to do this. Any help is appreciated. Thanks. Mendok |
|
|||
|
damcey@gmail.com wrote:
> I'm wondering if it's possible to delay write of CustomLog directive > instead of writting to file as soon as request is made ? I believe it > should be possible to pipe data to external program that will store > log in buffer and then write it after a delay, say every 10 seconds > but I'm not aware of program that is able to do this. Any help is buffered logging is already available in apache. for apache 2.0.41+ and newer, buffered logging is a mod_log_config configuration option that you can enable via httpd.conf: http://httpd.apache.org/docs/2.2/mod...l#bufferedlogs The BufferedLogs directive causes mod_log_config to store several log entries in memory and write them together to disk, rather than writing them after each request. On some systems, this may result in more efficient disk access and hence higher performance. It may be set only once for the entire server; it cannot be configured per virtual-host. for apache 1.3b2 -> 2.0.40, you can probably enable log buffering in httpd.h by setting: #define BUFFERED_LOGS or by adding -DBUFFERED_LOGS as a flag to your c compiler. hth --sean -- sean dreilinger - http://durak.org/sean/ |
| Thread Tools | |
| Display Modes | |
|
|