How would a create a bind record to redirect www.country.domain.com to country.domain.com?
closed as off topic by Indrek, random♦ Jan 11 at 17:48
Questions on Super User are expected to relate to computer software or computer hardware within the scope defined in the FAQ. Consider editing the question or leaving comments for improvement if you believe the question can be reworded to fit within the scope. Read more about closed questions here.
|
Redirection is an HTTP concept. It doesn't apply to DNS and involves the browser making multiple separate attempts to fetch a resource. To direct browsers to the correct IP-address you create DNS records that directly ("A" records) or indirectly ("CNAME" records) associate the domain name with the IP-address. For BIND you'd typically add a "CNAME" record for "www" to the forward zonefile for the parent domain ("country.domain.com" in your example). Update To redirect HTTP traffic you typically use one of two methods
(The Wikipedia page linked above describes other methods) In this context redirect means that the browser fetches one URL but is told by the HTTP server to discard the response and immediately fetch a different URL - this different URL would normally then be displayed in the address bar. |
|||||||
|
www IN CNAME @, I think. That's more usually done with a rewrite rule at the httpd level, though. – Xyon Jan 11 at 13:59