Why won't my cPanel document root changes take?
I'm trying to change a site's Document root using cPanel and when I submit the change, it never takes. What's going on?
2 Replies
If you are trying to update the main domain, you'll need to log into your Linode server via SSH to locate and edit the below file. Make sure to replace your user & domain info.
/var/cpanel/userdata/USERNAME/DOMAIN.COM
Then, you can follow the steps outlined below to complete the change:
- Open the file and look for the following line:
documentroot: /home/USERNAME/public_html
Save it and exit.
If you have SSL installed, the configuration file for SSL will also need to be update.
This file is available at the location:
/var/cpanel/userdata/username/domain_SSL .
- Rebuild the Apache conf and restart Apache:
/scripts/rebuildhttpdconf
service httpd restart
There are the instructions for modifying an addon domain using cPanel's web interface. I recommend reaching out to their support or the cPanel community if you are having trouble with this.
cPanel Support Resources: