1

How do I assign the ELB (Elastic Load Balancer) to my domain. Do I need to do it for the main domain (ie. domain.com) or sub domain (www.domain.com). My registrar is godaddy - how I do it? - What's the most recommended way?

I also later want to redirect traffic from non-www to www (301 redirect via IIS) or vice versa and I need it to work.

1

If you're using AWS's Route53 with ELB this isn't a problem to point the example.com to an ELB CNAME record. Short of that it has to be done by a service rather than through DNS because of RFC 1034 section 3.6.2 paragraph 3 which reads:

... If a CNAME RR is present at a node, no other data should be present; this ensures that the data for a canonical name and its aliases cannot be different. This rule also insures that a cached CNAME can be used without checking with an authoritative server for other RR types.

In other words it states that you can not have a CNAME RRset with any other RRset and a domain name record requires at a minimum 2 RRsets (SOA & NS) there by making it mutually exclusive with a CNAME RRset.

GoDaddy gets around this by offering domain Forwarding on their DomainManager details for the Domain Information. This updates the DNS record for your domain to point to one of their servers and it redirects the web-based domain requests to another URL. I utilize this for several domains that I have hosted with GoDaddy and running behind AWS ELBs. You just point the entry for www.example.com to your ELB CNAME RRset and then with the Forwarding in enable it'll be redirected as expected.

To accomplish the same without using GoDaddy, you would have to have a host with a static IP, or EC2 instance with an EIP, running Apache or some other web server that could simply issue a 301 or 302 redirect back to www.example.com. I have also found that EasyDNS also offers a URL forwarding feature the appears to provide the same functionality as GoDaddy's but I have not had a chance to try it out.

  • I'm using Amazon Route53 and now try to use interstate53.com to do it. I've set the CNAME to the ELB dns, but I don't know what information to put in the 'Alias' for the non-www domain in the Hosted ID field (See image here: picturepush.com/public/6765561). need your help on this – Idan Shechter Oct 16 '11 at 16:22

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.