Forums Sign Up Reply Search Statistics
HOW-TO setup PLESK GraFX Software Solutions - Forum / HOW-TO setup PLESK /

Debian, suPHP installation problems

 
Author huglester
Forums Member
#1 Posted: 19 Apr 2010 12:57:29
Reply 
Hello everyone,

I'm under Debian, and have come to problems with suPHP

The modicifations I did is the: /etc/suphp/suphp.conf :

docroot=/var/www/vhosts
also tried changing:
php5-script="php:/usr/bin/php-cgi"
to:
php5-script="php:/usr/bin/php5-cgi"

I also have modified vhost.conf
from:
php_admin_flag engine On
to:
php_admin_flag engine off

- because with 'On' suPHP was not working at all, files created via browser were owned by www-data.

Later, when I did: php_admin_flag engine off - suPHP started working, files were created with required permissions, but mod_rewrite happens to be broken...

If I remove vhost.conf - mod_rewrite is back to normal...

Actually I think there is issue with Plesk on Debian (even php5-cgi) rather than suPHP itself...

Can you guys share your thoughts...?

Thank you very much!
Author software
Admin
#2 Posted: 20 Apr 2010 06:28:30
Reply 
- did you checked the logs anyway?
- also do you have a symlink to /etc/suphp/suphp.conf in /etc/suphp.conf?
Author huglester
Forums Member
#3 Posted: 21 Apr 2010 17:37:21
Reply 
Hello,

yes I have tried creating a symlink, but this didn't help..
Logs.. apache access logs do not show anything abnormal
no logs at 'errors_log' also...

later, if I have
'php_admin_flag engine on' in vhost.conf, suphp logs to not show anything

if I do 'off'
then I get:
[Wed Apr 21 17:11:49 2010] [info] Executing "/var/www/vhosts/page.com/subdomains/pinigai/httpd ocs/index.php" as UID 10087, GID 2522
(I have changes /etc/suphp/suphp.conf loglevel=info, to have more info in logs)

Thanks for looking into my problem!
cheers,
Jaroslav
Author software
Admin
#4 Posted: 21 Apr 2010 22:03:08
Reply 
SuPHP is working on your server, we tested, but something is not OK with your htaccess.
You need to create php.ini in your folder always (Power Toys do this automatically) and also need to be sure that you tested, just change to root:root a file and if get error, suphp cannot run GUID lower then, then is OK.


[handlers]
;Handler for php-scripts
;x-httpd-php="php:/usr/bin/php"
php5-script="php:/usr/bin/php-cgi"
x-httpd-php="php:/usr/bin/php-cgi"

;Handler for CGI-scripts
x-suphp-cgi="execute:!self"


# PHP version detected 5
<IfModule mod_suphp.c>
<Directory "/var/www/vhosts/DOMAIN/subdomains/DOMAIN/httpdocs /">

php_admin_flag engine off
suPHP_Engine On
suPHP_ConfigPath "/var/www/vhosts/DOMAIN/subdomains/DOMAIN/httpdocs /"

AddHandler php5-script .php
AddHandler x-httpd-php .php .php3 .php4 .php5 .phtml
suPHP_AddHandler x-httpd-php
suPHP_AddHandler php5-script .php

<Files php.ini>
order allow,deny
deny from all
</Files>
php_value open_basedir "/tmp/"
php_value upload_tmp_dir "/var/www/vhosts/DOMAIN/subdomains/DOMAIN/httpdocs /tmp/"
</Directory>
</IfModule>
 
Your Reply

» Username  » Password 
Only registered users are allowed to post here. Please enter your login/password details upon posting a message, or sign up first.