Apache VirtualHost, multiple domains and subdomains on one IP
I'm having some problems to configure the httpd.conf with multiple domains and subdomains on one IP.
I'm able to run a single domain with its subdomains, but multiple domains with multiple subdomains always returns me the 1st website of the config file.
I've read the doc, but it always concern multiple hosts or subdomains, not the mixed case.
So, i'd like to run 2 internet domains (with their respectives subdomains):
- xxx.domain1.com (alias: domain1.com)
(no separated logs, everything logged under domain1.com)
- xxx.domain2.com (alias: domain2.com)
(no separated logs, everything logged under domain2.com)
and the primary will be a local domain:
(own access and error logs)
So when I try to reach xxx.domain2.com it always displays me xxx.domain1.com
UseCanonicalName and HostnameLookups are Off
PS: as I'm new here and cannot post URLs containing "www" yet, i replaced "www" to "xxx" but it doesn't matter, just an ethetic point :P
Thanks for your quick reply,
Well, until today, I was running everything fine using only one domain name, domain1.com for example, without specifying any IP address somewhere in the config file.
Both domain1.com and domain2.com resolves to my public IP addr.
I'm behind a firewall (privave IP: 192.168.0.1), port 80 is routed to my machine (192.168.0.2).
|All times are GMT -5. The time now is 08:40 AM.|