• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

Problem with the Original Default Domain, and MY Domain.

I

infamous

Guest
Hey, I just purchased a dedicated box through 1and1.com, and went through the install process ect ect, and Plesk comes with a pre-setup "default" domain folder, which all the httpd.conf files point to as the standard folder for my website. The domain that came already-installed in Plesk was "default-domain.com", and since i like to be organized, I went into the control panel in plesk and changed the name to digirev.us, my domain. Now the problem is, for somereason with the new digirev.us domain name, it doesnt pull from the .../vhosts/digirev.us/httpdocs folder, it pulls them from .../vhosts/default/htdocs

I know its a problem with plesk screwing up my httpd.conf files somewhere, but I wanted to know what I can do to fix them, so they wont be over-written anytime I make a change in Plesk.

Thanks
-Adam-
 
Originally posted by infamous
I know its a problem with plesk screwing up my httpd.conf files somewhere, but I wanted to know what I can do to fix them, so they wont be over-written anytime I make a change in Plesk.
First thing I would do is SSH root login to the server, and look through /etc/httpd/conf/httpd.conf and /etc/httpd/conf/httpd.include and change any occurances of 'default-domain.com' to your digirev.us name. Might as well check the domain's file as well:

/home/httpd/vhosts/digirev.us/conf/httpd.include

From the shell prompt, also do:

/usr/local/psa/admin/bin/websrvmng -u --vhost-name=digirev.us

Then restart apache service.


Just as a verification, check the /etc/httpd/conf/httpd.include file and locate the Include statement for digirev.us

"Include /home/httpd/vhosts/digirev.us/conf/httpd.include"

It should be just before the "<VirtualHost \ " section. If it is at the bottom of the file still, then you'll have to move it, save, restart apache.

Then I'd set your domain as the default for the IP address:

Login to Plesk CP and click on Server, click on IP Addresses.

In the column 'Hosting', click on the number on the IP address line.

Click on the dot for the domain digirev.us, click on the link 'Set as default'.

As to preventing Plesk from changing any of the apache config files, that would not be advised since anytime you use the Plesk control panel to make additions/deletions/changes to domains and subdomains, it needs to make changes to the apache files.
 
While yes, thats unadvised, but I atleast need to fix it so I dont have to move the lines of code every time I make a new domain, its very irritating.
 
Back
Top