No-www problem

I’ve got a weird problem with my nginx install. I cannot access any site
at
all without the www prefix. It’s probably my stupidity but I was
wondering
if anyone could help point out what my problem is. I’ve installed nginx
0.6.31 on debian 4.0 with php installed. when I set the server_name to
www.domain.tld the addresses resolve correctly but when I type in the
url
without the www-prefix it automatically adds the www prefix. If I set
the
server_name to domain.tld (without www) none of the addresses resolve
correctly. What am I doing wrong? Any help at all is greatly
appreciated.
Thanks in advance. Oh and in case you want to check out the problem it
is at
hazardcell.net. currently I set the server_name with the www prefix.

post your full config

On Fri, Jun 13, 2008 at 03:29:08AM +0100, Joe Jacobs wrote:

I’ve got a weird problem with my nginx install. I cannot access any site at
all without the www prefix. It’s probably my stupidity but I was wondering
if anyone could help point out what my problem is. I’ve installed nginx
0.6.31 on debian 4.0 with php installed. when I set the server_name to
www.domain.tld the addresses resolve correctly but when I type in the url
without the www-prefix it automatically adds the www prefix. If I set the
server_name to domain.tld (without www) none of the addresses resolve
correctly. What am I doing wrong? Any help at all is greatly appreciated.
Thanks in advance. Oh and in case you want to check out the problem it is at
hazardcell.net. currently I set the server_name with the www prefix.

You have no set A DNS record for hazardcell.net:

$host www.hazardcell.net
www.hazardcell.net has address 65.75.189.131

$host hazardcell.net
hazardcell.net mail is handled by 1 mail1.hazardcell.net.

It seems that Firefox (in my test) automatically retrys site with
the www prefix in this case.

Damn stupid me. Thanks a lot Igor.


Joe Jacobs
http://joejacobs.org/ | http://hazardcell.com