>Number:         2498
>Category:       mod_log-any
>Synopsis:       Revisitation of PR number 885
>Confidential:   no
>Severity:       critical
>Priority:       medium
>Responsible:    apache
>State:          open
>Class:          sw-bug
>Submitter-Id:   apache
>Arrival-Date:   Wed Jun 24 15:50:00 PDT 1998
>Last-Modified:
>Originator:     [EMAIL PROTECTED]
>Organization:
apache
>Release:        1.3.0
>Environment:
OS:
BSD/OS  2.1 BSDI BSD/OS 2.1 Kernel #1:
Mon Jun 10 15:58:19 MDT 1996
[EMAIL PROTECTED]:/usr/src/sys/compile/GENERIC  i386


Compiler:
gcc 2.7.2

The system load average is generally 1 or below.
The limits are all set to unlimited, or maxxed out,
and this has been proven by running the "limit" command
from within our CGI program:
"cputime unlimited
filesize unlimited
datasize 65536 kbytes
stacksize 65536 kbytes
coredumpsize unlimited
memoryuse unlimited
memorylocked 42529 kbytes
maxproc 2457
openfiles 6000"

We are NOT running through inetd.
We have one Apache server 1.2.5 with FrontPage extentions running on port
80, and another Apache 1.3.0 running on another port.  This 1.3.0 server
is the one where we're experiencing CGI problems (we don't allow CGIs to be
run from port 80).
>Description:
I am running a Unix system with ~8600 Time Warner web customers.

The server we're having a problem with has only one job:  to process CGI GET
requests and return the output.  It's not touched by regular user web page
requests or activity--those requests all come in on port 80.. This 1.3.0
server is on a different port (the actual port number is above 1000, but I
don't want to tell you what it is for security reasons, even though it
wouldn't make much difference anyway)

The problem I'm having is that occasionally (30 times a day in a sea of 8600
users) a GET request that runs a CGI program is not logged in the access or
error log files, even though the CGI program runs without a problem (until
the end), as evident from my CGI log routines.  No error is seen in the
error log file, not even "connection closed".

At the same time, the socket connection is closed from the server to the
client, as evident from a telnet connection to the server port, and a
SIGPIPE is sent to my CGI process when it tries to write the final output
to stdout (fd 1), as evident by a ktrace/kdump inspection.

Visibly, I can telnet to the server and type "GET 
/cgi-bin/<program>?parameter=name"
and sometimes I get appropriate output, and sometimes I get "Connection
closed by foreign host" after a few seconds.  When I get this message, the GET
request is not visible in any of the log files, but the CGI program gets
finished with the bulk of its work and receives a SIGPIPE because it tries
unsuccessfully to write any more to stdout.

Catching the SIGPIPE and ignoring it cause this error instead:
"CALL  write(0x1,0x13000,0x50)
 RET   write -1 errno 32 Broken pipe"

This looks VERY similar to PR number 885... Is it really closed?  What
help can you give me?  We are running a very critical mission with Time
Warner clients.

Is there any way to turn on extra logging from the server, to see if the
connection is closed or if the logger is dying?  Is there any way I can
recover the output if the logger is dying?  It is imperative that I see
the output coming from CGI.
>How-To-Repeat:
You can't connect to our servers unless you are a Road Runner customer, it's
protected by IP and other things.
>Fix:
We could work around it with a kludge, but it seems that the core issue
involves a problem in the server code--particulaly the logger.
>Audit-Trail:
>Unformatted:
[In order for any reply to be added to the PR database, ]
[you need to include <[EMAIL PROTECTED]> in the Cc line ]
[and leave the subject line UNCHANGED.  This is not done]
[automatically because of the potential for mail loops. ]



Reply via email to