0

I am examining a high-volume Apache prefork site and noticing that many log entries such as:

CustomLog '|/foo/bar/cronolog -foo -bar'
RewriteLog '|/foo/bar/cronolog -bar -foo'

When apache logs the request or the rewrite is cronolog spawned for EACH request or is the pipe opened and written-to for the lifetime duration of the preforked apache process?

(This was asked on stackoverflow but I'll remove from there as more applicable here I think.)

Jé Queue
  • 373

1 Answers1

1

It is spawned once per CustomLog directive.

So on my server where I use these two directives in the global scope only one copy of cronolog started and used for writing logs.

LogFormat "%v:%p %h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combinedvhost
CustomLog "|/usr/bin/cronolog /var/log/apache2/%Y%m.combined.allhosts.log" combinedvhost
Zoredache
  • 133,737