httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ben Johnson <>
Subject Re: [users@httpd] Apache 2.4 stability & ErrorLogFormat
Date Thu, 29 Nov 2012 22:14:40 GMT

On 11/29/2012 4:52 PM, Alvise Nicoletti wrote:
> Il 29/11/2012 21:36, Mark Montague ha scritto:
>> On November 29, 2012 14:46 , Alvise Nicoletti
>> <> wrote:
>>> I would like to use the ErrorLogFormat function (a > apache2.4 
>>> function),
>>> because I have a lot of php websites in a same Virtual Host /
>>> directory and I would like to have better error reporting.
>>> [...]
>>> So I ask, is 2.4 stable ?
>>> Do you have any tips to workaround the problem maybe with an apache
>>> mod ?
>> What does "stable" mean to you?  For what it is worth, 2.4 is a
>> production release of Apache HTTP Server: it is not a development
>> version, it is not an alpha version, and it is not a beta version.
>> People are using Apache HTTP Server 2.4 successfully in production. I
>> have not heard any complaints about it failing to serve its intended
>> purpose.
>> As for workarounds, you could try to backport the feature from 2.4 to
>> 2.2, but I recommend against this, in general:  if you have to compile
>> Apache HTTP Server from source, just compile an unmodified version of
>> 2.4 -- even counting the cost of learning about the new features and
>> making some changes to your existing configuration, I think this will
>> be much easier than backporting a feature to 2.2 and then supporting
>> it yourself in-house long term.
>> -- 
>>   Mark Montague
> Thanks,
> so you confirm it's actually impossible to have website URL reference in
> actual php error logs with apache 2.2 ... ?
> Of course I'm talking of a php application that is installed in a
> directory where is configured a virtual server with more than 1 website
> against it.
> Actually I have some php errors with /the/path/to/the/phpfile but I
> don't know wich website caused them.

Apache has no influence over how PHP logs its error messages.

Given that all of your "sites" are running on a single virtual host, how
do you expect Apache to know to which "site" the error is attributable?
Typically, a "site" equals a "virtual host". Therefore, there is no
Apache-specific change that will include the "site name" in PHP's error
log messages.

You state:

> Actually I have some php errors with /the/path/to/the/phpfile but I
> don't know wich website caused them.

You only have *one website* (one virtual host), based on your initial
post. What, exactly, are you hoping to see in your Apache logs? Can you
post a sample "ideal log entry"?

Doesn't the /the/path/to/the/phpfile contain the subdirectory (which you
seem to be equating with a "website") of interest?

The bottom line is that you would have to modify your PHP code; this is
out of Apache's hands. More specifically, you would have to override
PHP's base error-handling mechanism such that it includes whatever
information you're seeking.


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message