Re: VirtualHost problems

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> Listen 80
> NameVirtualHost 1.2.3.4:80
> 
> <VirtualHost 1.2.3.4:80>
> DocumentRoot /home/os/html/domain1
> ServerName www.domain1.com
> </VirtualHost>
> 
> <VirtualHost 1.2.3.4:80>
> DocumentRoot /home/os/html/domain2
> ServerName www.domain2.co.uk
> </VirtualHost>
> 

Hi,

Which version of apache do you have installed?
What value does the ServerName directive for the "main" server have?

When you have virtual hosts configured, the main server disappears. You
need to configure a virtual host for your main server.
You maybe also need a default virtual host or configure a virtual host
block before any other virtual host directive, which will be the default
virtual host.

<VirtualHost _default_:*>
DocumentRoot /dev/null
</VirtualHost>

If both virtual hosts should be reachable with the full qualified domain
name (without www), you must define a ServerAlias directive for each
virtual host.

http://httpd.apache.org/docs/2.0/en/vhosts/
http://httpd.apache.org/docs/2.0/en/vhosts/name-based.html
http://httpd.apache.org/docs/2.0/en/mod/core.html#virtualhost
http://httpd.apache.org/docs/2.0/en/mod/core.html#serveralias


kind regards,
Thomas


---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
   "   from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx


[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux