Did you switch to suexec with cPanel?

ffeingol

Well-Known Member
#1
Hello,

I'm just wondering how people handled switching to LSWS/phpsuexec and cPanel. We've tried it on one small server and run into all sorts of permissions problems (files owned by nobody:nobody). I'm sure we could run find commands and either change the ownership or the permissions but I'm wondering how people have handled it that have already switched.

Thanks,

Frank
 
#2
Code:
#!/bin/sh
for i in `ls /var/cpanel/users`
do
if [ -d /home/$i/public_html ]
then
chown -R $i:$i public_html/*
chown $i:nobody public_html
chmod 0750 public_html
fi
done
 

felosi

Well-Known Member
#5
Hello,

I'm just wondering how people handled switching to LSWS/phpsuexec and cPanel. We've tried it on one small server and run into all sorts of permissions problems (files owned by nobody:nobody). I'm sure we could run find commands and either change the ownership or the permissions but I'm wondering how people have handled it that have already switched.

Thanks,

Frank
hey on a fresh install its flawless. Ive setup 3 new cpanel servers lately as suexec with no problems at all. Converting is a bit more difficult but I dont think lsphp as suexec will give 500 errors on wrong perms liek mod_suphp does.
What medialayer posted or anything else that searches for nobody owned files will do the job.
Here is another you can sue for chmods of folders inside pub_html

find /home -perm 777 | xargs chmod 750
and so on.

But yeah Id much rather do a fresh install with suexec then convert a server thats been running as nobody for a while. My main server I converted it to suexec perms and owners and I ended up switching back to nobody because the server was simply too busy to run suexec and I ran into a lot of resource usage issues
 

ffeingol

Well-Known Member
#7
Yea, it's not quite as much an issue with the 500 errors like suexec as it is with galleries etc. The files are all owned by nobody and then there are issues.

BTW, if you guys have fantastico did you have to flip the setting in fantastico to say your suexec or just leave it normal?

Frank
 
#8
Well it is fairly simple to resolve the nobody issues using the quick for loop shown above.

For Fantastico you probably do need to enable that option as otherwise I would assume that it would chmod the files and folders to 666 and 777 which is not necessary.
 
Top