i have a VPS with multiple cpanel accounts (mine).
I thought i had suphp installed enabled, but if i have i don't think I have it working properly. My understanding is if it is working I cant set directories to 777. I have just installed a script setting folders to 777, config to 655 as required by the script, it happily installed. Shouldn't do this should it? or have I read it all wrong? I have googled till my eyes bled, but i still don't understand if it is working or not. Read a squillion posts and pages.
In WHM/Configure PHP it says:
PHP 5 Handler suphp
Apache suEXEC on
in my /usr/local/apache/conf/httpd.conf file it has:
suPHP_UserGroup nobody nobody
/etc/suphp.conf does not exist
I did not install suphp, it is a managed vps, and looks like it is part of the Apache install.
I could throw it at the host support, but i would love to get my head around it.
So if someone can tell me where i have stuffed up, point me in the right direction, I would be exceedingly grateful.
eNetCloud-CEO and asciiDigital, thanks - consensus gives confidence! Did so, some sites wouldn't load due to zend not installing. I let it load on default settings, it loads brightest and newest of everything, but latest zend wont work with php5.3.x.
So recompiled with php 5.2.9, latest that zend can handle.
Original problem persists - I can still change folders to 777, files to 666 in cpanel. Am I looking at this right? Should I be able to change to this permission level?
OK, I am straw-clutching here. Is it probable that I have de-tuned suphp by modifying a config file somewhere? That remains intact after a couple of apache rebuilds? And if so, what does anyone think it could be?
# This file was automatically generated by the Cpanel PHP Configuration system
# If you wish to change the way PHP is being handled by Apache on your system,
# use the /usr/local/cpanel/bin/rebuild_phpconf script or the WHM interface.
# Manual edits of this file will be lost when Apache is updated.
Is the issue that you can create a folder with 777 perms, or that anything you put in that folder will not execute? I think suPHP won't prevent you from creating the folder with those perms, but that it won't run anything from it.
You can still set 777 permissions, but having 777 permissions on your scripts or the directories they reside in will not run and will instead cause a "500 internal server error" when attempting to execute them, this is done to protect you from someone abusing your scripts. Your scripts and directories can now, only have a maximum of 755 permissions (read/write/execute by you, read/execute by everyone else) and be able to run.
3. What I would recommend is tailing those logs and visit the website that's not working with suPHP. Post the relevant log entries here. It could be a number of things, but without seeing the logs it's hard to say.
I don't think that they were saying their script isn't working.
I thought i had suphp installed enabled, but if i have i don't think I have it working properly. My understanding is if it is working I cant set directories to 777. I have just installed a script setting folders to 777, config to 655 as required by the script, it happily installed. Shouldn't do this should it?
I took that to mean that they installed the script just fine, but are confused about having been able to set 777 on a folder(s). As said in my last reply, 777 can be set even with suPHP; just not on any scripts or their containing folders, else an error will result.
Thanks to everyone for input.
My initial query was whether file perms could be changed to 777, some readings say you can't, or i took it that way. Thanks for that clarification James.
Tailing the suphp log shows all the 'executing user_file.php' as UID and GID, so that looks like a good thing.
I was concerned initially because I installed a billing script that required many folders to be set to 777, and would not install until they were. So I did, and it installed, then i changed them to 755, and it works fine.
I just changed them back to 777, and opened the page. The script displayed its own error page 'page not found'.
I checked the logs again, shows all the executions, though no mention of any problem or non-execution.
So, my summary... it is working, I am traveling under the protection of suphp, as I wanted. If you agree, thanks for all your help.
But if you think it is not working properly, please say, or suggest further tests. Thanks again.