RE: FastCGI + Apache2 + php4fcgi

"Tom Myny" <[email protected]>
Newsgroups gmane.comp.web.fastcgi.devel
Message-ID <[email protected]>
Hi Jack,

Correct

1) The php 'crashes' because fastcgi is killing the process.
Is there a way that fastcgi checks the process first (to see if its busy)
before killing it :) 

2) Has no implication on my problem, my processes are running fine (i think
;-) My fastcgi is working fine all the time (just execpt when fastcgi is
killing things to free resources)

Best Regards,
Tom

-----Oorspronkelijk bericht-----
Van: Jack [mailto:[email protected]] 
Verzonden: maandag 26 september 2005 21:57
Aan: Tom Myny
CC: fastcgi-developers-xGejAJT2w6xVgU18Zptdi0EOCMrvLtNR@public.gmane.org
Onderwerp: Re: [FASTCGI] FastCGI + Apache2 + php4fcgi

Hello Tom,

This is the reply of my question from jancha <[email protected]>
It might have something to do with the problem you are having.

------------------- cut --------------------
1) "Internal Server Error" - you get such error displayed if the underlying
program crashes for whatever reason.

2) Typically, if there are more than 3 crashes in 30secs, FastCGI puts a 
600second delay before launching a new process. Theoretically, you can patch

the fastcgi apache module. No other workaround for this.
------------------- cut --------------------

-- 
Best regards,
Jack

Monday, September 26, 2005, 11:38:49 AM, you wrote:

TM> Hi folks,

TM> I have the following problem after 300 seconds (default killinterval):

TM> Apache2 error logs:

TM> ....
TM> [Mon Sep 26 17:07:33 2005] [warn] FastCGI: (dynamic) server
TM> "/usr/local/apache2/cgi-bin/php" (pid 493) termination signaled
TM> [Mon Sep 26 17:07:33 2005] [warn] FastCGI: (dynamic) server
TM> "/usr/local/apache2/cgi-bin/php" (pid 706) termination signaled
TM> [Mon Sep 26 17:07:33 2005] [warn] FastCGI: (dynamic) server
TM> "/usr/local/apache2/cgi-bin/php" (pid 1214) termination signaled
TM> [Mon Sep 26 17:07:33 2005] [warn] FastCGI: (dynamic) server
TM> "/usr/local/apache2/cgi-bin/php" (pid 32554) termination signaled
TM> [Mon Sep 26 17:07:33 2005] [warn] FastCGI: (dynamic) server
TM> "/usr/local/apache2/cgi-bin/php" (pid 32589) termination signaled
TM> [Mon Sep 26 17:07:33 2005] [warn] FastCGI: (dynamic) server
TM> "/usr/local/apache2/cgi-bin/php" (pid 3541) termination signaled
TM> [Mon Sep 26 17:07:33 2005] [warn] FastCGI: (dynamic) server
TM> "/usr/local/apache2/cgi-bin/php" (pid 32326) termination signaled
TM> [Mon Sep 26 17:07:33 2005] [warn] FastCGI: (dynamic) server
TM> "/usr/local/apache2/cgi-bin/php" (pid 32575) termination signaled
TM> [Mon Sep 26 17:07:33 2005] [warn] FastCGI: (dynamic) server
TM> "/usr/local/apache2/cgi-bin/php" (pid 3447) termination signaled
TM> [Mon Sep 26 17:07:33 2005] [warn] FastCGI: (dynamic) server
TM> "/usr/local/apache2/cgi-bin/php" (pid 4053) terminated by calling exit
with
TM> status '0'
TM> [Mon Sep 26 17:07:33 2005] [warn] FastCGI: (dynamic) server
TM> "/usr/local/apache2/cgi-bin/php" (pid 4059) terminated by calling exit
with
TM> status '0'
TM> [Mon Sep 26 17:07:33 2005] [warn] FastCGI: (dynamic) server
TM> "/usr/local/apache2/cgi-bin/php" (pid 4064) terminated by calling exit
with
TM> status '0'
TM> [Mon Sep 26 17:07:33 2005] [warn] FastCGI: (dynamic) server
TM> "/usr/local/apache2/cgi-bin/php" (pid 4092) terminated by calling exit
with
TM> status '0'
TM> [Mon Sep 26 17:07:33 2005] [warn] FastCGI: (dynamic) server
TM> "/usr/local/apache2/cgi-bin/php" (pid 4132) terminated by calling exit
with
TM> status '0'
->> and here is the problem
TM> [Mon Sep 26 17:07:33 2005] [error] [client 212.100.181.46] FastCGI:
TM> incomplete headers (0 bytes) received from server
TM> "/usr/local/apache2/cgi-bin/php"
TM> [Mon Sep 26 17:07:33 2005] [error] [client 81.245.161.224] FastCGI:
TM> incomplete headers (0 bytes) received from server
TM> "/usr/local/apache2/cgi-bin/php", referer: http:// www.sitexxx.be
TM> /shop.php?p=buy&s=12&x=Ninja&y=1&login=koop
TM> [Mon Sep 26 17:07:33 2005] [warn] FastCGI: (dynamic) server
TM> "/usr/local/apache2/cgi-bin/php" (pid 4092) terminated by calling exit
with
TM> status '0'
TM> [Mon Sep 26 17:07:33 2005] [warn] FastCGI: (dynamic) server
TM> "/usr/local/apache2/cgi-bin/php" (pid 4132) terminated by calling exit
with
TM> status '0'
->> again
TM> [Mon Sep 26 17:07:33 2005] [error] [client 212.100.181.46] FastCGI:
TM> incomplete headers (0 bytes) received from server
TM> "/usr/local/apache2/cgi-bin/php"
TM> [Mon Sep 26 17:07:33 2005] [error] [client 81.245.161.224] FastCGI:
TM> incomplete headers (0 bytes) received from server
TM> "/usr/local/apache2/cgi-bin/php", referer:
TM> http://www.sitexxx.be/shop.php?p=buy&s=12&x=Ninja&y=1&login=koop

TM> Sometimes a fastcgi proces is killed while its used by the webserver
TM> (resulting in a Internal Server Error on the webserver)
TM> This is not always the case, but you can count it happens 10 times each
TM> hour.

TM> --
TM> My apache config:

TM> FastCgiWrapper /usr/local/apache2/bin/suexec
TM> FastCgiServer /usr/local/apache2/cgi-bin/php -user apache -group apache
TM> FastCgiConfig -startDelay 2 -singleThreshold 25 -multiThreshold 50
TM> -autoUpdate -idle-timeout 30 -maxClassProcesses 20 -maxProcesses 100
TM> -pass-header Authorization
TM> --

TM> Setting singleThreshold to 0 is no option, my fastcgi's processes have
to be
TM> killed after some time. (I have +1000 vhosts in the apache config, with
+400
TM> suexecusers)

TM> --
TM> /usr/local/apache2/cgi-bin/php 

TM> #!/bin/sh
TM> PHPRC="/usr/local/apache2/cgi-bin"
TM> export PHPRC
TM> PHP_FCGI_CHILDREN=2
TM> export PHP_FCGI_CHILDREN
TM> exec /usr/local/apache2/cgi-bin/php4.fcgi
TM> --

TM> Someone have an idea ?

TM> Best Regards,
TM> Tom Myny

___________________________________
fastcgi-developers mailing list
http://fastcgi.com/fastcgi-developers/
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.