Linode.com Forum Forum Index Linode.com Forum
Linode Community Forums
 


All domains showing same web content in linode

Click here to go to the original topic

 
       Linode.com Forum Forum Index -> Linux, Apache, Mysql and PHP (LAMP) Forum
Author Message
smeago



Joined: 18 May 2008
Posts: 8

Posted: Sun May 18, 2008 10:26 am    Post subject: All domains showing same web content in linode  

Hi, all. I 'm quite new in linux. Please pardon me if I don,t use the right terminology. I ,m using Ubuntu 7.04 and I have webmin and virtualmin installed as control panels. I recently configured my two domains to linode dns and they point fine to my linode. However when try to host the domains in my linode, both domains show the same web contents.

I'm really confused. What do I do?
Back to top  
nazerim



Joined: 05 Nov 2007
Posts: 1

Posted: Sun May 18, 2008 11:17 am    Post subject:  

You'll need to check that your webmin/virtualmin is setting up the VirtualHost(s) inside apache correctly. Debian based distributions should have the apache configuration within /etc/apache (or /etc/apache2)

For an example of what it's supposed to be:

http://httpd.apache.org/docs/1.3/vhosts/examples.html
Back to top  
smeago



Joined: 18 May 2008
Posts: 8

Posted: Sun May 18, 2008 11:46 pm    Post subject: can't acess configuration file  

Thanks. But I can't find the configuration file : /etc/apache2 for the configuration settings. I can create virtual hosts automatically with virtualmin for two domains : www.mydomain1.com, www.mydomain2.com . Both domains resolve to my server IP. How can I access the apache configuration file on ubuntu 7.04?
Back to top  
smeago



Joined: 18 May 2008
Posts: 8

Posted: Mon May 19, 2008 5:57 am    Post subject:  

Still trying to resolve the problem. When I restarted apache this is what I got:
[Mon May 19 06:50:27 2008] [error] VirtualHost xxx.xxx.xxx.xxx:0 -- mixing * ports and non-* ports with a NameVir
tualHost address is not supported, proceeding with undefined results
[Mon May 19 06:50:27 2008] [error] VirtualHost xxx.xxx.xxx.xxx:0 -- mixing * ports and non-* ports with a NameVir
tualHost address is not supported, proceeding with undefined results
[Mon May 19 06:50:27 2008] [warn] NameVirtualHost xxx.xxx.xxx.xxx:80 has no VirtualHosts
[Mon May 19 06:50:27 2008] [warn] NameVirtualHost *:0 has no VirtualHosts
[Mon May 19 06:50:27 2008] [warn] NameVirtualHost *:0 has no VirtualHosts
[Mon May 19 06:50:37 2008] [error] VirtualHost xxx.xxx.xxx.xxx:0 -- mixing * ports and non-* ports with a NameVir
tualHost address is not supported, proceeding with undefined results
[Mon May 19 06:50:37 2008] [error] VirtualHost xxx.xxx.xxx.xxx:0 -- mixing * ports and non-* ports with a NameVir
tualHost address is not supported, proceeding with undefined results
[Mon May 19 06:50:37 2008] [warn] NameVirtualHost xxx.xxx.xxx.xxx:80 has no VirtualHosts
[Mon May 19 06:50:37 2008] [warn] NameVirtualHost *:0 has no VirtualHosts
[Mon May 19 06:50:37 2008] [warn] NameVirtualHost *:0 has no VirtualHosts



xxx.xxx.xxx.xxx is my IP.

Thanks.
Back to top  
irgeek



Joined: 21 Jun 2003
Posts: 98
Location: Denver, CO

Posted: Mon May 19, 2008 7:20 am    Post subject: Try Google!  

One minute of Googling your error message turned up this: http://wiki.apache.org/httpd/VirtualHostsMixingPorts

Also, I don't know where the xxx.xxx.xxx.xxx:0 and *:0 are coming from--Apache shouldn't be listening on port 0 normally.
Back to top  
smeago



Joined: 18 May 2008
Posts: 8

Posted: Tue May 20, 2008 2:34 am    Post subject: Mixing Ports problem fixed, but problem still exists  

Thanks. I have fixed the port mixing problem. But all my domains still showing the same web contents. I only upload web pages in one of my domain which I have configured to linode dns but all other domains show the same web pages even when I did not uplaod to the virtual hosts.


Any further help will be appreciated.


Thanks.
Back to top  
Navi



Joined: 20 May 2008
Posts: 17

Posted: Sun May 25, 2008 7:13 am    Post subject:  

I've had the same problem, everything non-configured by virtualmin showed up the first domain I did configure, but I've added this to my /etc/httpd/conf/httpd.conf file at the section where all the Vhosts were :

Code:
<VirtualHost xx.xx.xx.xx:80>
DocumentRoot /var/www/html
<Directory /var/www/html>
Options Indexes IncludesNOEXEC FollowSymLinks
allow from all
AllowOverride All
</Directory>
</VirtualHost>


Now it shows up as empty (since /var/www/html is empty too), could also post a message there or whatever.

I'm on CentOS btw, so the config might differ.
Back to top  
smeago



Joined: 18 May 2008
Posts: 8

Posted: Mon May 26, 2008 12:09 am    Post subject: I will try this out and see  

Thanks. I will try this out and see how it goes.
Back to top  
SwellJoe



Joined: 27 Jun 2007
Posts: 3

Posted: Mon Jun 02, 2008 4:17 am    Post subject:  

This problem is discussed in the Virtualmin documentation:

http://www.virtualmin.com/documentation/id,troubleshooting_common_problems/#the_wrong_site_shows_up

It's basically exactly what the previously linked Apache documentation talked about.

In short you've got ports and addresses configured incorrectly in your Apache configuration--Virtualmin doesn't touch the NameVirtualHost directives (though you can set them in Webmin's Apache module), and so if you've configured it incorrectly all of your virtual hosts will be broken.

And to answer the earlier suggestion that Webmin or Virtualmin may not know about Debian-based distros locations, it definitely does. Debian and Ubuntu are both well-supported (and Jamie and I use Debian on some of our own systems).
Back to top  
 
       Linode.com Forum Forum Index -> Linux, Apache, Mysql and PHP (LAMP) Forum
Page 1 of 1