Problems with php5-fcgi-starter and suexec - smallFire - 03-10-2008 03:57 AM
I have some problems after an upgrade from rc2 to rc3 on Ubuntu Dapper:
My error-log:
Code:
[Sun Mar 09 18:51:20 2008] [warn] FastCGI: (dynamic) server "/var/www/fcgi/master/php5-fcgi-starter" (uid 0, gid 0) restarted (pid 30733)
[Sun Mar 09 18:51:20 2008] [warn] FastCGI: (dynamic) server "/var/www/fcgi/master/php5-fcgi-starter" (pid 30733) terminated by calling exit with status '107'
and my suexex.log
Code:
[2008-03-09 18:41:20]: uid: (root/root) gid: (0/0) cmd: php5-fcgi-starter
[2008-03-09 18:41:20]: cannot run as forbidden uid (0/php5-fcgi-starter)
[2008-03-09 18:51:20]: uid: (root/root) gid: (0/0) cmd: php5-fcgi-starter
[2008-03-09 18:51:20]: cannot run as forbidden uid (0/php5-fcgi-starter)
It look likes the wrong username is parsed to php5-fcgi-starter. Does anyone have any hints to solve this problem?
RE: Problems with php5-fcgi-starter and suexec - joximu - 03-10-2008 04:07 AM
have a look in
- /etc/apache2/mods-enabled/fastcgi_ispcp.conf
- the User/Group Settings in .../sites-enabled/00_master.conf
- the Owner of /var/www/fcgi/master
/J
RE: Problems with php5-fcgi-starter and suexec - smallFire - 03-10-2008 04:24 AM
/etc/apache2/mods-enabled/fastcgi_ispcp.conf
Code:
<IfModule mod_fastcgi.c>
FastCgiWrapper On
FastCgiIpcDir /var/lib/apache2/fastcgi2
FastCgiConfig -minProcesses 1 -maxProcesses 10 -singleThreshold 100
#-killInterval 300 \
#-autoUpdate \
#-idle-timeout 240 \
#-pass-header HTTP_AUTHORIZATION
FastCgiServer /var/www/fcgi/master/php5-fcgi-starter -user vu2000 -group v
#
# PHP5 SUPPORT
#
AddHandler php-fastcgi .php .php5
<Location /php5/php5-fcgi-starter>
SetHandler fastcgi-script
Options +ExecCGI
</Location>
Action php-fastcgi /php5/php5-fcgi-starter
AddType application/x-httpd-php .php .php5
</IfModule>
the User/Group Settings in .../sites-enabled/00_master.conf
Code:
#
# Master Begin
#
<VirtualHost 85.25.130.132:80>
ServerAdmin xxx@web.de
DocumentRoot /var/www/ispcp/gui
ServerName admin.alphaXXX.server4you.de
ErrorLog /var/log/apache2/users/admin.alphaXXX.server4you.de-error.log
TransferLog /var/log/apache2/users/admin.alphaXXX.server4you.de-access.log
CustomLog /var/log/apache2/admin.alphaXXX.server4you.de-traf.log traff
CustomLog /var/log/apache2/admin.alphaXXX.server4you.de-combined.log com
Alias /errors /var/www/ispcp/gui/errordocs/
ErrorDocument 401 /errors/401.html
ErrorDocument 403 /errors/403.html
ErrorDocument 404 /errors/404.html
ErrorDocument 500 /errors/500.html
ErrorDocument 503 /errors/503.html
Alias /pma /var/www/ispcp/gui/tools/pma/
Alias /webmail /var/www/ispcp/gui/tools/webmail/
Alias /ftp /var/www/ispcp/gui/tools/filemanager/
<IfModule suexec_module>
SuexecUserGroup vu2000 vu2000
</IfModule>
<Directory /var/www/ispcp/gui>
Options -Indexes Includes FollowSymLinks MultiViews
AllowOverride None
Order allow,deny
Allow from all
</Directory>
<IfModule mod_fastcgi.c>
ScriptAlias /php4/ /var/www/fcgi/master/
ScriptAlias /php5/ /var/www/fcgi/master/
<Directory "/var/www/fcgi/master">
AllowOverride None
Options +ExecCGI MultiViews -Indexes
Order allow,deny
Allow from all
</Directory>
</IfModule>
<IfModule mod_php4.c>
<Directory /var/www/ispcp/gui>
php_admin_value open_basedir "/var/www/ispcp/gui/:/etc/ispcp/:/proc/:/
php_admin_value session.save_path "/var/www/ispcp/gui/phptmp/"
</Directory>
</IfModule>
<IfModule mod_php5.c>
<Directory /var/www/ispcp/gui>
php_admin_value open_basedir "/var/www/ispcp/gui/:/etc/ispcp/:/proc/:/
php_admin_value session.save_path "/var/www/ispcp/gui/phptmp/"
</Directory>
</IfModule>
</VirtualHost>
#
# Master End
#
the Owner of /var/www/fcgi/master
Code:
drwxr-xr-x 2 root root 4096 2007-05-01 22:52 php4
-rwxr-xr-x 1 vu2000 vu2000 196 2008-03-09 16:28 php4-fcgi-starter
drwxr-xr-x 2 root root 4096 2007-05-01 22:55 php5
-rwxr-xr-x 1 vu2000 vu2000 195 2008-03-09 18:43 php5-fcgi-starter
Looks all fine for me...
RE: Problems with php5-fcgi-starter and suexec - joximu - 03-10-2008 04:33 AM
Hi
the one line is cut I assume... "FastCgiServer...."
is suexec_module loaded?
try to comment the 2 lines:
<IfModule suexec_module>
and
</IfModule>
so the SuexecUserGroup is set (try to set) in all situations...
I also recommend the newer fastcgi_ispcp.conf - since RC3
http://www.isp-control.net/ispcp/browser/trunk/configs/apache/fastcgi2.conf
but this should not be the problem.
RE: Problems with php5-fcgi-starter and suexec - smallFire - 03-10-2008 08:48 AM
Hi, I changed it to:
Quote:#<IfModule mod_fastcgi.c>
FastCgiWrapper On
FastCgiIpcDir /var/lib/apache2/fastcgi2
FastCgiConfig -minProcesses 1 -maxProcesses 400 \
-multiThreshold 80 -maxClassProcesses 5 -killInterval 60 \
-startDelay 5 \
-idle-timeout 300
#-pass-header HTTP_AUTHORIZATION
FastCgiServer /var/www/fcgi/master/php5-fcgi-starter -user vu2000 -group vu2000
#
# PHP5 SUPPORT
#
AddHandler php-fastcgi .php .php5
<Location /php5/php5-fcgi-starter>
SetHandler fastcgi-script
Options +ExecCGI
</Location>
Action php-fastcgi /php5/php5-fcgi-starter
AddType application/x-httpd-php .php .php5
#</IfModule>
and the result:
Code:
[Sun Mar 09 23:42:32 2008] [warn] FastCGI: server "/var/www/fcgi/master/php5-fcgi-starter" (uid 2000, gid 2000) started (pid 24555)
[Sun Mar 09 23:42:32 2008] [notice] Apache configured -- resuming normal operations
[Sun Mar 09 23:43:29 2008] [warn] FastCGI: (dynamic) server "/var/www/fcgi/master/php5-fcgi-starter" (uid 0, gid 0) started (pid 24680)
[Sun Mar 09 23:43:29 2008] [warn] FastCGI: (dynamic) server "/var/www/fcgi/master/php5-fcgi-starter" (pid 24680) terminated by calling exit with status '107'
[Sun Mar 09 23:43:34 2008] [warn] FastCGI: (dynamic) server "/var/www/fcgi/master/php5-fcgi-starter" (uid 0, gid 0) restarted (pid 24685)
[Sun Mar 09 23:43:34 2008] [warn] FastCGI: (dynamic) server "/var/www/fcgi/master/php5-fcgi-starter" (pid 24685) terminated by calling exit with status '107'
[Sun Mar 09 23:43:39 2008] [warn] FastCGI: (dynamic) server "/var/www/fcgi/master/php5-fcgi-starter" (uid 0, gid 0) restarted (pid 24686)
[Sun Mar 09 23:43:39 2008] [warn] FastCGI: (dynamic) server "/var/www/fcgi/master/php5-fcgi-starter" (pid 24686) terminated by calling exit with status '107'
[Sun Mar 09 23:43:44 2008] [warn] FastCGI: (dynamic) server "/var/www/fcgi/master/php5-fcgi-starter" (uid 0, gid 0) restarted (pid 24689)
[Sun Mar 09 23:43:44 2008] [warn] FastCGI: (dynamic) server "/var/www/fcgi/master/php5-fcgi-starter" (pid 24689) terminated by calling exit with status '107'
[Sun Mar 09 23:43:44 2008] [warn] FastCGI: (dynamic) server "/var/www/fcgi/master/php5-fcgi-starter" has failed to remain running for 30 seconds given 3 attempts, its restart interval has been backed off to 600 seconds
[Sun Mar 09 23:43:45 2008] [warn] FastCGI: (dynamic) server "/var/www/fcgi/master/php5-fcgi-starter" has failed to remain running for 30 seconds given 3 attempts, its restart interval has been backed off to 600 seconds
RE: Problems with php5-fcgi-starter and suexec - joximu - 03-10-2008 09:05 AM
You see?
the first server is started correctly - the next not (uid:gid 0:0).
so, I think you need some corrctions in your apache config
apache2 -M
apache2 -S
and check the
<IfModule suexec_module>
SuexecUserGroup vu2000 vu2000
</IfModule>
/J
RE: Problems with php5-fcgi-starter and suexec - smallFire - 03-10-2008 10:01 AM
Code:
<IfModule suexec_module>
SuexecUserGroup vu2000 vu2000
</IfModule>
[x] checked
What do you mean with Quote:so, I think you need some corrctions in your apache config
apache2 -M
apache2 -S
apache2 -S is not finding any errors.
RE: Problems with php5-fcgi-starter and suexec - joximu - 03-10-2008 10:37 AM
you have to make sure, that the user:groups are set correct for your vhosts.
but you know it better - right?
RE: Problems with php5-fcgi-starter and suexec - smallFire - 03-10-2008 11:24 AM
Well, I'll resigned. Luckily I've backuped all my config files and now the system is up and running (with RC2...) - Maybe next weekend I'll try it again. Thanks for you help!
|