Return-Path: Delivered-To: apmail-httpd-dev-archive@httpd.apache.org Received: (qmail 64675 invoked by uid 500); 23 Apr 2003 14:44:18 -0000 Mailing-List: contact dev-help@httpd.apache.org; run by ezmlm Precedence: bulk Reply-To: dev@httpd.apache.org list-help: list-unsubscribe: list-post: Delivered-To: mailing list dev@httpd.apache.org Received: (qmail 64584 invoked from network); 23 Apr 2003 14:44:17 -0000 Message-ID: <3EA6A6FD.1080904@attglobal.net> Date: Wed, 23 Apr 2003 10:45:17 -0400 From: Jeff Trawick Reply-To: trawick@attglobal.net User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.3) Gecko/20030312 X-Accept-Language: en-us, en MIME-Version: 1.0 To: dev@httpd.apache.org Subject: Re: Scripts generating 4069+ bytes of STDERR logs jam Apache 2.0.45 References: <20030423143203.GA4246@freshdot.net> In-Reply-To: <20030423143203.GA4246@freshdot.net> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N Sander Smeenk wrote: > I'm using Apache 2.0.45 (mpm-prefork). Recently I discovered that Apache2 > doesn't like it very much when a CGI-script that it runs, generates > about 4K of debug data. yep, known problem it will also stall if your cgi tries to write more than 4K of output (stdout or stderr) before reading all of the request body (e.g., post data) (replace 4K in my text and yours with your kernel's pipe buffer size) I have hacked up^H^H^H^H^H^H^H^H^Hheavily revised mod_cgi to handle a CGI's stdin/stdout/stderr "properly". With this change it no longer matters in which order your script chooses to do I/O on stdin/stdout/stderr. But a) it currently buffers the entire reponse for non-nph scripts since I haven't yet taught it when to process the script headers b) other changes are not completely tested c) no support yet for weenie operating systems like Win32 where APR can't poll on pipes d) because it doesn't alter the filter API or make funny things happen in the filter support code, but instead uses normal multi-plexed I/O idioms directly in mod_cgi, I'm afraid some people might not like my solution You're free to play with it if you want. > > Is there any way to have Apache2 error.log's in simple format? > I only want the errors, not prefixed with date, time, type and client, > and postfixed with a referrer URL. I couldn't find anything yet. > It's really hard to read script debug information now ;) > ErrorLog |/path/to/user/provided/reformatter Reformat it to your heart's desire.