PHP 5.3.2 + Fcgid 2.3.5 + Apache 2.2.14 + SuExec => Connection reset by peer: mod_fcgid: error reading data from FastCGI server
- by Zigzag
I'm trying to use PHP 5.3.2 + Fcgid 2.3.5 + Apache 2.2.14 but I always have the error : "Connection reset by peer: mod_fcgid: error reading data from FastCGI server".
And Apache returns an error 500 each time I tried to execute a php page :
I have compiled the Apache with this options:
./configure --with-mpm=worker --enable-userdir=shared --enable-actions=shared --enable-alias=shared --enable-auth=shared --enable-so --enable-deflate \
--enable-cache=shared --enable-disk-cache=shared --enable-info=shared --enable-rewrite=shared \
--enable-suexec=shared --with-suexec-caller=www-data --with-suexec-userdir=site --with-suexec-logfile=/usr/local/apache2/logs/suexec.log --with-suexec-docroot=/home
Then PHP:
./configure --with-config-file-path=/usr/local/apache2/php --with-apxs2=/usr/local/apache2/bin/apxs --with-mysql --with-zlib --enable-exif --with-gd --enable-cgi
Then FCdigd:
APXS=/usr/local/apache2/bin/apxs ./configure.apxs
The VHOST is:
<Directory /home/website_panel/site/>
FCGIWrapper /home/website_panel/cgi/php .php
...
ErrorLog /home/website_panel/logs/error.log
</Directory>
cat /home/website_panel/logs/error.log
[Sun Mar 07 22:19:41 2010] [warn] [client xx.xx.xx.xx] (104)Connection reset by peer: mod_fcgid: error reading data from FastCGI server
[Sun Mar 07 22:19:41 2010] [error] [client xx.xx.xx.xx] Premature end of script headers: test.php
[Sun Mar 07 22:19:41 2010] [warn] [client xx.xx.xx.xx] (104)Connection reset by peer: mod_fcgid: error reading data from FastCGI server
[Sun Mar 07 22:19:41 2010] [error] [client xx.xx.xx.xx] Premature end of script headers: test.php
[Sun Mar 07 22:19:42 2010] [warn] [client xx.xx.xx.xx] (104)Connection reset by peer: mod_fcgid: error reading data from FastCGI server
[Sun Mar 07 22:19:42 2010] [error] [client xx.xx.xx.xx] Premature end of script headers: test.php
[Sun Mar 07 22:19:43 2010] [warn] [client xx.xx.xx.xx] (104)Connection reset by peer: mod_fcgid: error reading data from FastCGI server
[Sun Mar 07 22:19:43 2010] [error] [client xx.xx.xx.xx] Premature end of script headers: test.php
The Suexec log:
root:/usr/local/apache2# cat /var/log/apache2/suexec.log
[2010-03-07 22:11:05]: uid: (1001/website_panel) gid: (1001/website_panel) cmd: php
[2010-03-07 22:11:15]: uid: (1001/website_panel) gid: (1001/website_panel) cmd: php
[2010-03-07 22:11:23]: uid: (1001/website_panel) gid: (1001/website_panel) cmd: php
[2010-03-07 22:19:41]: uid: (1001/website_panel) gid: (1001/website_panel) cmd: php
[2010-03-07 22:19:41]: uid: (1001/website_panel) gid: (1001/website_panel) cmd: php
[2010-03-07 22:19:42]: uid: (1001/website_panel) gid: (1001/website_panel) cmd: php
[2010-03-07 22:19:43]: uid: (1001/website_panel) gid: (1001/website_panel) cmd: php
root:/usr/local/apache2# cat logs/error_log
[Sun Mar 07 22:18:47 2010] [notice] suEXEC mechanism enabled (wrapper: /usr/local/apache2/bin/suexec)
[Sun Mar 07 22:18:47 2010] [notice] mod_bw : Memory Allocated 0 bytes (each conf takes 32 bytes)
[Sun Mar 07 22:18:47 2010] [notice] mod_bw : Version 0.7 - Initialized [0 Confs]
[Sun Mar 07 22:18:47 2010] [notice] Apache/2.2.14 (Unix) mod_fcgid/2.3.5 configured -- resuming normal operations
root:/usr/local/apache2# /home/website_panel/cgi/php -v
PHP 5.3.2 (cli) (built: Mar 7 2010 16:01:49)
Copyright (c) 1997-2010 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2010 Zend Technologies
If someone has got an idea, I want to hear it ^^
Thanks !