Shark Stone

Member
Feb 20, 2010
9
0
51
I have been transferring accounts over from another cpanel server but on the new server all accounts public_html dir get set to 750. How could I stop this?
 

Spiral

BANNED
Jun 24, 2005
2,018
8
193
750 is the correct permission setting for the "public_html" folder itself and should be "(user login)" owned and "nobody" group.
 

madaboutlinux

Well-Known Member
Jan 24, 2005
1,051
2
168
Earth
Right, 750 is the default permission of 'public_html' directory on a cPanel server. If you are having trouble accessing the new account with the 750 permission, make sure the owner is set to the 'user' and group is set to 'nobody' for the public_html directory.

A quick way to correct the ownership of all the accounts is to execute the following 'for' loop

for i in `cat /etc/trueuserdomains | awk '{print $2}'`
do
chown $i.nobody /home/$i/public_html;
done;
 

oscarfish

Registered
Mar 25, 2010
4
0
51
Hello friends,
i am also facing the same issue. When i transfer sites using cpanel transfer feature the public_html folder and even the directories inside public_html folder of sites have chmod 750 and even the sites are not opening its showing Internal Server Error 500.

So can anyone help me out with this?

Thnx in advance.
 

mohit

Well-Known Member
Jul 12, 2005
553
0
166
Sticky On Internet
Hello friends,
i am also facing the same issue. When i transfer sites using cpanel transfer feature the public_html folder and even the directories inside public_html folder of sites have chmod 750 and even the sites are not opening its showing Internal Server Error 500.

So can anyone help me out with this?

Thnx in advance.
it may be incorrect php setup.
can be a permission issue with file/folder not just "public_html" folder.
check the error log why error 500 is thrown.
 

Spiral

BANNED
Jun 24, 2005
2,018
8
193
When i transfer sites using cpanel transfer feature the public_html folder and even the directories inside public_html folder of sites have chmod 750 and even the sites are not opening its showing Internal Server Error 500.
Do you notice that in my original post above that I underlined the word "itself" when talking about "public_html" to emphasize the point that the ONLY folder that should be 750 is just 'public_html' alone.

(For Reference: Folders beneath public_html are typically set to 755)

If you are getting 750 for files or folders BENEATH public_html when you do transfers then there is something very wrong and the first thing I would take a look at is your default permission setting in "Tweak Settings" in WHM as those may possibly be setup incorrectly.
 

Spiral

BANNED
Jun 24, 2005
2,018
8
193
On the mention of "transferring sites", one more note ....

If you are transferring between any of these combination, you are likely going to run into serious problems if you don't correct for the permission, ownership, and htaccess command differences:

DSO server <-> SuPHP server
DSO server <-> FCGI server
DSO server <-> phpSuExec server

CGI (non-suexec) <-> SuPHP / FCGI / or phpSuExec (rare)

Generally speaking, you are usually okay changing between this:

SuPHP server <-> FCGI server

If moving a site away from a location that was originally DSO based, you must eliminate all '777' permissions, make all file and folders owned by the user, and remove all 'php_flag' and 'php_value' commands from .htaccess or you will run into Error 500 page problems.

In the reverse of that, getting a sit from a non-DSO system and moving it to a server that is DSO based (you are insane doing that :rolleyes: ) then you would need to make sure that files that must be writable are set to 666 or looser and any scripts running tighter suexec style permissions (600 for example) would have to be loosened to 644 else you may again run into problems being able to view your web site.