Update from 1.0.0 to trunk: PHP files not interpreted - Printable Version +- ispCP - Board - Support (http://www.isp-control.net/forum) +-- Forum: ispCP Omega Support Area (/forum-30.html) +--- Forum: Update/Upgrade (/forum-44.html) +--- Thread: Update from 1.0.0 to trunk: PHP files not interpreted (/thread-11675.html) Pages: 1 2 |
Update from 1.0.0 to trunk: PHP files not interpreted - nuke3d - 09-16-2010 07:05 AM Hi, I've made an update today from v 1.0.0 to the current trunk. After clearing the tickets table the updated ran fine (the updated failed when updating this table so I just emptied it). Now the problem is that PHP code is not run but displayed to the user when opening a page. Couriously enough this only applies to customer pages not to the admin interface. I've been on this for hours now and I have absolutely no idea how to further debug this. I'd be glad to hear your ideas on this subject and I'll try to supply you with as much information as possible: in ispcp.conf Quote:PHP_FASTCGI = fcgid suexec.log, all fine Quote:[2010-09-15 22:36:18]: uid: (2010/vu2010) gid: (2010/vu2010) cmd: php5-fcgi-starter /var/log/apache2/users/domain.com-error.log Quote:[Wed Sep 15 22:54:24 2010] [notice] mod_fcgid: call /var/www/virtual/domain.com/htdocs/index.php with wrapper /var/www/fcgi/domain.com/php5-fcgi-starter /var/log/apache2/other_vhosts_access.log (weird that this isn't in the correct file domain.com-access.log) Quote:domain.com:80 IP - - [15/Sep/2010:22:54:24 +0200] "GET / HTTP/1.1" 200 1119 "-" "Opera/9.80 (Windows NT 6.1; U; en) Presto/2.6.30 Version/10.62" apache2 error.log is empty php5-fcgi-starter Quote:#!/bin/sh How can I get further debug information on how the request is handled? Thanks a lot! RE: Update from 1.0.0 to trunk: PHP files not interpreted - nuke3d - 09-16-2010 11:12 AM Some additional information: - When I go to http://domain.com the PHP code is not interpreted and the index.php is printed out to the user. - When I rename the index.php to index.php.old fcgid apparently tries to run it directly but fails because it's not an executable (!!! could this be a security hole? Seems like arbitrary executables could be run by the user. Only with his own credentials, but stil...). The line in suexec.log then reads: Quote:uid: (2010/vu2010) gid: (2010/vu2010) cmd: index.php.oldand then some error message. - When I rename index.php to index.old it wants to download the file as expected - When I then change the line Quote:FCGIWrapper /var/www/fcgi/domain.com/php5-fcgi-starter .phpin "/etc/apache2/sites-enabled/ispcp.conf" to Quote:FCGIWrapper /var/www/fcgi/domain.com/php5-fcgi-starter .oldIt correctly runs the index.old file as a PHP script! Mind = blown... RE: Update from 1.0.0 to trunk: PHP files not interpreted - kilburn - 09-17-2010 04:22 PM Which distro/version are you using? I would recommend using fcgid with anything >etch... RE: Update from 1.0.0 to trunk: PHP files not interpreted - nuke3d - 09-17-2010 08:39 PM It's a Debian Lenny, and I'm using fcgid. Here are the loaded modules: Quote:# apache2ctl -t -D DUMP_MODULES RE: Update from 1.0.0 to trunk: PHP files not interpreted - nuke3d - 09-18-2010 05:51 AM If I replace Quote:<?with Quote:<?phpit works! Now, why does this only apply to .php files? As stated above, if I rename it to .old and change the fcgid line to handle .old files it works even with Quote:<? Seems like short_open_tag was changed to Off in ispcp, this breaks all of my hosted php sites. RE: Update from 1.0.0 to trunk: PHP files not interpreted - ZiomekPL - 09-22-2010 12:33 AM edit /etc/ispcp/fcgi/parts/php5/php.ini for new domains and sed exists files in /var/www/fcgi/ RE: Update from 1.0.0 to trunk: PHP files not interpreted - Nuxwin - 09-22-2010 03:38 AM hello http://isp-control.net/ispcp/changeset/3319 RE: Update from 1.0.0 to trunk: PHP files not interpreted - nuke3d - 09-22-2010 04:28 AM Ah, k... thx. I'm already maintaining a patchset with customizations RE: Update from 1.0.0 to trunk: PHP files not interpreted - MasterTH - 09-22-2010 03:32 PM you can also edit the php.ini of the domain which has the problem. RE: Update from 1.0.0 to trunk: PHP files not interpreted - RatS - 09-23-2010 06:27 AM When I replaced the php.ini file, they had "short_open_tag = Off" (default value) for PHP5, in PHP4 it was still on. There is an ongoing discussion in the PHP mailing is to deprecate it. I'd say nuke3d should activate it in the php.ini files of the domains that need it and we should revert r3319 back. |