Hello people.. im in serious need of some help here.. I have a VPS and i have installed Webmin. After that, i have installed mysql, apache. I have multiple sites i want to host on that VPS, but have a problem setting them up. I have uploaded all the files to the home directory (files from my previous server) and i go to Servers - Apache. I click on the Create new virtual host. I insert the correct settings (i have done it in the past, with a managed vps, and some help from the host). Everything works great for one site.. but when i create a second virtual server for my second domain, when i then visit it, the first domain appears. I am not using BIND, i don't want to set up DNS servers, im using external DNS from afraid.org, and point A records to the server IP. Ive been Googling all day about this but cant find a solution. Anyone had the same problem..? any fix? heeelp, please!!
Make sure the IP you are using is not assigned to the first domain i.e. not set as a Dedicated IP for the first domain. It should act as a Shared IP and it will fix the issue. Also check the Apache configuration file manually and see of the VirtualHost entry is correct? The configuration file is located at /etc/httpd/conf/httpd.conf
Yes the settings are correct and yes, i restart Apache after every change. I have only 1 server IP. Is there a setting to use it as a Shared IP and not a dedicated, as it currently appears to be?
If the settings and entries are correct then the only problem looks like with the IP. BTW, the IP is used as a Shared IP unless defined as Dedicated so shouldn't create issues either but it's worth having someone to look into the server settings for you.