Hi suomi,
Thank you for your answer. Unfortunately I am not using php-fpm but fcgid. As far as I know there is no such possibility in fcgid.
Any other ideas?
Sandro
From: fedora <fedora@xxxxxxxx>
Sent: Thursday, May 11, 2017 6:54 AM
To: users@xxxxxxxxxxxxxxxx
Subject: Re: cgi script error output loggingHi Sandro
are you using php-fpm as a cgi frontend? If yes: the stdout and stderr
are both redirectet to the php-fpm log (/var/log/php-fpm/*) if you have
in /etc/php-fpm/www.conf:
catch_workers_output = yes
I don't think this will solve all your problems, but it is a good
starting point.
suomi
On 05/10/2017 03:59 PM, KASPAR Sandro wrote:
>
> Hi,
>
> According to this documentation http://httpd.apache.org/docs/2.4/logs.html everything a cgi script sends to stderr is written to the apache error log file.
>
> Unfortunately I can not control those scripts running on my server and often garbage is sent to stderr and then written to my error log. Because there isn't even a timestamp or any other useful information on those lines, I can't find out, which vhost created the error. In addition those log lines often lack a "new line" at the end, and it the next log message gets appended to the current line instead of being written to a new line. Because of this, the next line which would have been in the correct format is also lost, because it can't be parsed automatically anymore.
>
> Is there any way to change this behaviour? What I would like to achieve is to have the cgi errors in a seperate logfile or even better change the log format of these lines. For example prefix the log line with the vhost and a timestamp.
> Because I don't have control over the cgi scripts, I would need to configure this in apaches main or vhost configuration. Unfortunately I could not find anything about cgi script output logging in the apache documentation (except that everything sent to stderr is written to httpd-error.log) or mailing list archives.
>
> Any ideas appreciated. Thanks in advance!
>
> Sandro Kaspar
> ------------------------------------------------------------ ---------
> To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
> For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx
>
------------------------------------------------------------ ---------
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx