CNAME ?

John Wobus jw354 at cornell.edu
Wed Feb 27 22:04:15 UTC 2008


On Feb 27, 2008, at 3:51 PM, sasi-technique wrote:
> Hi,
> I'm quite new  in Bind configuration so I hope someone can answer 
> this. In
> Bind DNS entrie, Is there a way to do this :
>
> When people tape http://domain.com redirect to http://www.domain.com ?
>
> Thanks in advance.
>
> Best regards,
> F. Sabino

Redirects are an HTTP function, set up in your webserver.

Mainstream web browsers don't support any DNS lookups that would tell
them that the name 'domain.com' is handled by a server called 
'www.domain.com'.
(Wouldn't it be nice if they did!)  Furthermore, a CNAME record making 
domain.com
an alias of www.domain.com is not legal DNS.

Instead, the typical DNS setup for such pairs is one of the following:

-Set up an A record for domain.com that points to the same IP address 
that www.domain.com resolves to.

-Set up a CNAME record that makes www.domain.com an alias for 
domain.com.

You can look up the DNS for many domains on the Internet and see 
examples of both.
In either case, the webserver configuration would determine whether the 
server
accepts both names, and what it does with such queries.

John Wobus

(Tell your browser provider to support HTTP SRV records!  You can 
unseat that windmill!)



More information about the bind-users mailing list