AWS Route53 - delegate subdomain - amazon-web-services

I created two public hosted zones in AWS Route53:
domain.com
sub.domain.com
In "sub.domain.com" zone I added "A" record for "test.sub.domain.com" name resolved to 10.0.1.5. I can resolve "test.sub.domain.com" name using "sub.domain.com" name servers.
> nslookup test.sub.domain.com <sub.domain.com server>
Name: test.sub.domain.com
Address: 10.0.1.5
Following instruction for Creating a Subdomain That Uses Amazon Route 53 as the DNS Service, in "domain.com" zone I added "NS" record for "sub.domain.com" pointed to the "sub.domain.com" zone name servers.
Now, when I try to resolve "test.sub.domain.com" name using "domain.com" zone name servers, I get response that name is served by "sub.domain.com" servers, but it cannot resolve to IP address. Below is example of "nslookup" response:
> nslookup test.sub.domain.com <domain.com server>
Name: test.sub.domain.com
Served by:
- <sub.domain.com server>
sub.domain.com
Does Route53 support subdomain delegation to other Route53 servers? Have I missed something in the configuration?

It seems to me that you're asking how to use Route53 NS records from within other Route53 domains?
Well, as it turns out it's very much verbatim - you go to your sub.domain.com, copy its 4 NS records (that Route53 had generated automatically when it was created), and paste them as NS records for the name "sub" within the domain.com.
(And then wait for the TTLs to expire, etc)
I think there was already one such question and answer somewhere on the StackExchange network, but I couldn't find it now.

What you are describing is how DNS works. Recursive name servers would follow the name server referral and ask the name servers for sub.domain.com to resolve test.sub.domain.com.
You can try this out by doing a dig +trace test.sub.domain.com, assuming your are delegating domain.com to the route 53 you configured in the .com zone.

In addition to Josip Rodin's answer I had to add A record to my subdomain hosted zone as an alias to my Elastic Beanstalk environment.
After this and TTL expired all started working.

Related

how to let web application use the purchased domain name through ROUTE 53 in AWS?

I have purchased a domain name through ROUTE 53.
2) I have created a EC2 instance and put my web application inside it that is supposed to be hosted.
3) I have configured the Gunicorn and nginx as my WSGI and web server.
How to use the purchased domain name to integrate with my application to see over the internet. I have seen many documents post on stackoverflow, and youtube videos. But I am not able to get the clear picture of what am suppose to do next.
I get that once the domain is registered I have 4 ns records generated inside the ROUTE 53. But where to use them? how to configure them.
It be helpful if somebody can give me exact steps to perform the tasks.
Thank you,
Route53 is similar to other DNS servers with extra features, in your case, you will need to assign your ec2 instance a public IP address and to be safe an Elastic IP to avoid IP change on reboot, then you need to grab this public IP and assign it to your domain root A record and www CNAME record to point to that domain
I get that once the domain is registered I have 4 ns records generated
inside the ROUTE 53. But where to use them? how to configure them.
Normally it's not required but it's helpful to control your DNS configuration from route 53 instead of the DNS registrar.
Create Hosted zone in route 53, for example if your domain name is example.com then create Hosted zone in route with name example.com, it will generate name server record.
Open newly created hosted zone and copy Name server (NS) record and replace the NS record in your DNS setting.
When you create a hosted zone, Route 53 automatically creates a name server (NS) record and a start of authority (SOA) record for the zone. The NS record identifies the four name servers that Route 53 associated with your hosted zone. To make Route 53 the DNS service for your domain, you update the registration for the domain to use these four name servers.
Add these record in DNS Name server, for example the below one is used for Godaddy
migrating-a-domain-to-amazon-route53

How to forward a subdomain from AWS Route53 to an external DNS

I'm trying to get a subdomain to resolve to my AWS server (sub.example.com), while the example.com domain needs to resolve to another server (Wix).
Currently, the NS on my host site redirects example.com to Amazon's Route53 DNS:
ns-1.awsdns-5.org.
ns-2.awsdns-6.co.uk.
ns-3.awsdns-7.net.
ns-4.awsdns-8.com.
On Route53 I have set two different hosted zones, one for sub.example.com where I have the same NS setup and one for example.com where the NS redirects to Wix:
ns1.wixdns.net
ns2.wixdns.net
When I try to access the different domains, sub.example.com works as expected but example.com cannot be resolved.
I have also tried to set the same zone host for the both of the domains by adding to example.com a NS specific to the subdomain with the addresses shown above, to no avail.
What am I doing wrong here?
Based on your comment, if you only want the subdomain to handle requests routed to the load balancer; simply create a CNAME record in your DNS provider zone:
sub.domain.com. 3599 IN CNAME your-load-balancer-123456789.us-west-2.elb.amazonaws.com.

Lightsail instance works when you hit http://[domain].com, but not www.[domain].com, using Route 53 as DNS

I'm pretty new to DNS and this is the first time trying to connect a domain name to an IP, so I'm not sure what I'm missing here. I tried connecting both the www and non www NS records to the Lightsail name servers but only the non www option seems to be working. When I try to hit www.[domain].com, I get unresolved hostname. I also added an A record in each hosted zone that points directly to the IP and I'm not sure if they actually did anything, but I can only access the site from the IP or from http://[domain].com. I appreciate any help you guys can give me, hoping its something small.
Here is an album containing my hosted zone and each zone's settings
I think you don't need to use two separate hosted zone for www and the apex domain (non-www). You can have a single hosted zone and create resource record set for www and the apex domain using CNAME or Alias records. Since you already have an A-record for example.com, in the same hosted zone you can create a CNAME record for www.example.com and point it to example.com
Regardless, for the domain not found, it could be due to the TTL.
Hope this helps.
More information:
http://docs.aws.amazon.com/Route53/latest/DeveloperGuide/ResourceRecordTypes.html#CNAMEFormat
http://docs.aws.amazon.com/Route53/latest/DeveloperGuide/resource-record-sets-values-basic.html#rrsets-values-basic-ttl

AWS route53 doesnt resolve any records

I have such problem - Route53 does not resolve any added ( A,CNAME, ALIAS ) records to world, but resolve if i execute it with aws NS server
nslookup x.site.com ns-1583.awsdns-57.org
Server: ns-1583.awsdns-57.org
Address: 205.251.197.203#53
Name: x.site.com
Address: address
What it could be ?
Are you sure that your domain registrar is configured to use Amazon DNS servers?
Visit http://whois.domaintools.com/site.com to confirm.
Replace the site.com above with your actual domain. Then check to make sure the assigned name servers on the domain point to the name servers assigned to your domain at Route 53.
Problem was in different NS-serervers on domain registrator and route53.
Thanks for help.
Closed

AWS EC2 and Route 53 Domain ( Transfered from different Provider ) Linking Issues | nslookup doesnt resolve any ip address

I am new to AWS and having trouble in linking my recently transferred domain to the EC2 Web application which is running on Ubuntu.
Cpnfigurations
EC2 Setup is done.
Assigned an Elastic IP to EC2.
Assigned liost of Name Servers to Recently transferred domains.
Created Hosted Zone with new A record with
Name: mydomain.com
Alias : no
Value :
When try to Access My web application using static IP it works fine. Hoever, with domain it doesnt seems resolving the host.
nslookup for domain gives below result
Server: UnKnown
Address: fe80::1
DNS request timed out.
timeout was 2 seconds.
*** Request to UnKnown timed-out
Any help would be appreciated. Thanks in Advance
Thank you so much for providing all these information.
I have few additional information from http://viewdns.
info Missing NS records at local servers
oops! It appears that the following name serves listed at the parent servers are not listed at your local servers:
ns-1089.awsdns-08.org.
ns-1886.awsdns-43.co.uk.
ns-431.awsdns-53.com.
ns-765.awsdns-31.net.
Local nameservers answer authoritively
Oops! The following nameservers do not answer authoritatively for your domain:
ns-431.awsdns-53.com.
ns-765.awsdns-31.net.
ns-1089.awsdns-08.org.
ns-1886.awsdns-43.co.uk.
Missing NS records at local servers
Oops! It appears that the following nameserves listed at the parent servers are not listed at your local servers:
ns-1089.awsdns-08.org.
ns-1886.awsdns-43.co.uk.
ns-431.awsdns-53.com.
ns-765.awsdns-31.net.**
After testing your domain and re-reading your question, I realized that this is likely the problem:
Created Hosted Zone with new A record with Name: mydomain.com Alias :
no Value :
Since you're just using an individual EC2 instance you don't want to be using an alias. As the Route53 documentation states, aliases only apply to Elastic Load Balancers, S3 buckets, CloudFront (CDN) endpoints, and records within the same domain.
What you likely want to do is remove any A records that you have defined and then create a CNAME for mydomain.com (not an alias) that has a value of the EC2 DNS record for your instance. You might also want to create a www.mydomain.com record that is also a CNAME to your EC2 DNS record.
Once you've created those CNAME records then nslookup should give you results something like this:
$ nslookup mydomain.com
Server: 10.1.2.11
Address: 10.1.2.11#53
Non-authoritative answer:
mydomain.com canonical name = ec2-111-222-123-1.eu-west-1.compute.amazonaws.com.
Name: ec2-111-222-123-1.eu-west-1.compute.amazonaws.com
Address: 111.222.123.1
Don't forget that when you make changes to your DNS records it will take some time for those changes to take effect when you test it. Route53 defaults to a TTL of 300 seconds (5 minutes) so unless you changed the TTL you should see the change reflected within 5 minutes. You can see how many seconds are left in the TTL if you use dig instead of nslookup:
$ dig www.news.com
...
;; ANSWER SECTION:
www.news.com. 234 IN CNAME phx1-rb-gtm3-tron-xw-lb.cnet.com.
The "234" there means that the local DNS server will expire this result in 234 seconds and query the authoritative DNS server once again. You'll need to wait for that value to hit 0 before your local DNS server will look up mydomain.com or www.mydomain.com the next time around.
Edit:
I would suggest double-checking your nameservers in Route53 and verify them in your domain registration. If I do a whois on your domain it shows:
$ whois trueweekends.in
...
Name Server:NS-1089.AWSDNS-08.ORG
Name Server:NS-765.AWSDNS-31.NET
Name Server:NS-431.AWSDNS-53.COM
Name Server:NS-1886.AWSDNS-43.CO.UK
I should be able to query any of those nameservers and get a listing of the same nameservers back from them. For example, take a look at the domain todoist.com, which is also hosted on AWS:
$ whois todoist.com
...
Name Server: NS-938.AWSDNS-53.NET
Name Server: NS-1046.AWSDNS-02.ORG
Name Server: NS-1799.AWSDNS-32.CO.UK
Name Server: NS-158.AWSDNS-19.COM
If I query one of those nameservers for a list of nameservers associated with todoist.com then I get:
$ dig #NS-938.AWSDNS-53.NET todoist.com NS
...
;; ANSWER SECTION:
todoist.com. 172800 IN NS ns-1046.awsdns-02.org.
todoist.com. 172800 IN NS ns-158.awsdns-19.com.
todoist.com. 172800 IN NS ns-1799.awsdns-32.co.uk.
todoist.com. 172800 IN NS ns-938.awsdns-53.net.
If I do the same sort of thing with your domain I don't get any results. The following queries all result in no answers:
$ dig #NS-1089.AWSDNS-08.ORG trueweekends.in NS
$ dig #NS-765.AWSDNS-31.NET trueweekends.in NS
$ dig #NS-1799.AWSDNS-32.CO.UK trueweekends.in NS
$ dig #NS-158.AWSDNS-19.COM trueweekends.in NS
If you're 100% sure that you have the correct nameservers listed in your domain (the ones I mention above match what Route53 shows you should be using) and you're sure your records within Route53 are set up properly then I would suggest contacting AWS support because it sounds like there's some sort of issue with Route53 not handling your domain properly.