Default directory changed on one account

JohnR

Member
Dec 12, 2002
8
0
151
I moved an account from one server to another and on the new server the default directory is now /public_html/www/ instead of the normal (to me at least) /public_html/

There are several accounts on the server the site was moved to and they are all working as expected. The account was moved using the account password but so were several of the others.

Searches have not returned any ideas and I am out of things to look at. Any ideas here?
 

cPanelTristan

Quality Assurance Analyst
Staff member
Oct 2, 2010
7,607
42
348
somewhere over the rainbow
cPanel Access Level
Root Administrator
Check /var/cpanel/userdata/username/domain.com to see the "documentroot" listed there for the account where username is the cPanel username and domain.com is the domain name. If the documentroot listed in the file is the wrong path, change to the correct path, then run the following commands to back up Apache's configuration (httpd.conf file), rebuild Apache and restart Apache:

Code:
cp /usr/local/apache/conf/httpd.conf /usr/local/apache/conf/httpd.conf.bak110330
/scripts/rebuildhttpdconf
/etc/init.d/httpd restart
This should correct the issue for the domain's default document root. You can also check httpd.conf at /usr/local/apache/conf/httpd.conf after running the rebuildhttpdconf command to ensure it now shows the right document root for the domain. If you don't see the site working after the Apache restart (the last command), please check in a proxy such as proxify.net or kproxy.com as many times you might still be cached after correcting the path for the site.
 

JohnR

Member
Dec 12, 2002
8
0
151
That seems to have done it. Thanks! Not sure why it was wrong but appears to be working now.