PHP5 + Apache + mpm_worker fcgid problem

Discussion in 'Server Operation' started by kipikipi, Feb 1, 2010.

Thread Status:
Not open for further replies.
  1. kipikipi

    kipikipi New Member

    Hi there,
    I've a problem using fcgid in apache for running php scripts (i'd like to run MediaWiki, i've no problem when i use mpm_prefork).
    I saw many post about the subject but no one could resolve my problem.
    here is my configuration :

    --------------------------
    /etc/apache2/mods-enabled/fcgid.conf :
    <IfModule mod_fcgid.c>
    Alias /wiki/ /srv/www/wiki/
    MaxRequestsPerProcess 500
    IPCConnectTimeout 60
    <Location /wiki/>
    AddHandler fcgid-script .php
    Options +ExecCGI
    FcgiWrapper /srv/php-wrapper .php
    </Location>
    </IfModule>

    --------------------------
    /etc/apache2/sites-enabled/default :
    <VirtualHost *:80>
    ErrorLog "/srv/log/default-error.log"
    LogLevel debug
    CustomLog "/srv/log/default-access.log"

    DocumentRoot "/srv/www/"

    <Directory /srv/www/wiki>
    AllowOverride all
    Order allow,deny
    Allow from all
    </Directory>
    </VirtualHost>

    --------------------------
    /srv/php-wrapper :
    #!/bin/sh
    PHP_FCGI_MAX_REQUESTS=10000
    export PHP_FCGI_MAX_REQUESTS
    exec /usr/bin/php5-cgi
    --------------------------
    With this config, i have in error log :
    [debug] mod_cache.c(131): Adding CACHE_SAVE filter for /wiki
    [debug] mod_cache.c(138): Adding CACHE_REMOVE_URL filter for /wiki
    [debug] mod_deflate.c(615): [client 127.0.0.1] Zlib: Compressed 230 to 172 : URL /wiki
    [debug] mod_cache.c(131): Adding CACHE_SAVE filter for /wiki/
    [debug] mod_cache.c(138): Adding CACHE_REMOVE_URL filter for /wiki/
    [warn] (104)Connection reset by peer: mod_fcgid: read data from fastcgi server error.
    [error] [client 127.0.0.1] Premature end of script headers: index.php
    [debug] mod_deflate.c(615): [client 127.0.0.1] Zlib: Compressed 539 to 321 : URL /wiki/index.php


    I've try to increase values of MaxRequestsPerProcess and IPCConnectTimeout, because I saw it solved the problem for some people.... But nothing for me !

    Please, someone could help ?
     
  2. falko

    falko Super Moderator Howtoforge Staff

    Which distribution do you use?
     
  3. kipikipi

    kipikipi New Member

    I use debian Linux. But I found my error since yesterday ... sorry to not post it... My error was I had not gave the good rights to php-wrapper script (not executable and not accessible by www-data).
    Thanks for reply ! You can mark thread as resolved ^^
     
Thread Status:
Not open for further replies.

Share This Page