Nginx assuming all non-specified domains are handled by another vhost

Igor Sysoev is at rambler-co.ru
Sat Oct 20 12:36:22 MSD 2007


On Sat, Oct 20, 2007 at 01:05:32AM +0100, James Darling wrote:

> I'm not quite sure how to explain my problem, hence a failure to  
> google effectively, so I don't know if this problem is unique or not,  
> or whether it's me or a bug.
> 
> I have many domains, and therefore have many vhosts. One of them is  
> abscond.org, my personal site. However, any domains that don't have a  
> vhost get sent to the abscond.org vhost. And if I create a default  
> vhost, I get the following error on start, despite only mentioning  
> the term abscond.org once.
> 
> nginx2007/10/19 20:57:29 [warn] 16880#0: conflicting server name  
> "abscond.org" on 0.0.0.0:8080, ignored
> 
> I think it's best to show you my test config files with just two  
> domains and output directly, so I've outlined my issue in a pastie -  
> please see http://pastie.caboo.se/108975

If you did not define "server_name" in "server {}", then nginx use
hostname as server_name. It's seems that your hostname is abscond.org.

You may set

    server_name  _ *;

as it was already suggested.
"_" is simple nonexistent domain name.


-- 
Igor Sysoev
http://sysoev.ru/en/





More information about the nginx mailing list