1

Possible Duplicate:
Multiple domains on Amazon AWS EC2

I am trying to setup multiple domains to point to the same IP address under one hosted zone, but keep on getting hosted zone issues from Amazon Route 54 (error says cannot add "mydomain.com" under zone "mymainip")

This is what I did so far:

  1. I created a new zone with the main IP address as the name
  2. I created a A record for the IP address and set the same IP address as the value

Now I am trying to add other domain names as CNAME records that point to this A record, but it is not working.

How can I achieve this? Amazon charges $1 per month for every hosted zone - I have many domains and if I have to get a hosted zone for each domain this would be way to expensive. So how do I get several domains point to the same IP address under one hosted zone?

I am using an Apache server and have the virtual hosts setup for all the domains, now I am just trying to setup a DNS and have them point to my Apache server.

4
  • 1
    $1 per hosted zone is too expensive? How many domain names do you have?
    – joeqwerty
    Aug 17, 2011 at 15:50
  • I'm not familiar with the Amazon Route 54 implementation, but a "zone" in DNS is all records under a single domain. So www.abc.com, mail.abc.com, and goatporn.abc.com are all under the abc.com zone. If you want to create records for www.xyz.com, you need to create a zone for xyz.com.
    – Hyppy
    Aug 17, 2011 at 15:56
  • 1
    Well if I have 30 domains that would be $30 a month just for DNS, meanwhile I can get a shared host for $5 a month and setup A records for as many domains as I want...
    – Zack
    Aug 17, 2011 at 16:56
  • 1
    Not to nit pick, but it's Route 53. And yes you need one zone per domain. Aug 18, 2011 at 14:48

1 Answer 1

1

It sounds like you're putting the CNAME records for the other zones in the zone that they'll be pointing to?

This will not work; a CNAME is essentially an alias that says "look there, instead" - but it needs to be where it's pointing from, not to.

So, say I want to send www.foo.com over to centralserver.mainsite.com.

Someone will enter www.foo.com into their browser, and DNS resolution will (this is the simplified version - there's more steps) ask the foo.com domain for a www record - which would then point to centralserver.mainsite.com.

There isn't going to be any way around having those zones hosted somewhere - clients have no way to know to look in the central domain for the other domain's records.

3
  • So there is no way to use one hosted zone to have different domains point to the same ip? I would have to get a separate hosted zone for each domain then?
    – Zack
    Aug 17, 2011 at 16:54
  • @Zack Correct. The zones that you're pointing to your central device must be where the CNAME records are located, and therefore must be hosted somewhere. Aug 17, 2011 at 16:57
  • How come on my shared host, all of the domains point to the same DNS server, but yet each domain has their own A record, meanwhile when I create a new zone with Amazon I am always given different DNS's. Maybe a dumb question, but I want clarify this to keep my sanity.
    – Zack
    Aug 17, 2011 at 17:29

Not the answer you're looking for? Browse other questions tagged .