Open In App

How To Configure Amazon Route 53 In AWS

Last Updated : 22 Jan, 2024
Improve
Improve
Like Article
Like
Save
Share
Report

In this article, we’ll learn the basics of DNS management, and how to configure our domain with AWS Route53, add DNS records, customize the attributes in DNS records, monitor the health status of the record, and make our site live.

Prerequisites

To configure the AWS Route53 you should have the following things:

  • Active AWS Account
  • Registered Domain
  • Access to AWS Management Console
  • Understanding of DNS Concepts
  • Domain Registrar Access
  • Knowledge of AWS Route 53 Basics

What is Amazon Route53?

AWS Route 53 service provides highly available and scalable DNS hosting services. Using Route 53, you can register domains, route DNS, and also monitor DNS record health. Do you know something? Big wigs like McDonald’s, Netflix, and Slack use AWS route53 for DNS Hosting.

What is AWS Route 53 used for?

AWS Route53 is a reliable and cost-effective way to route end users to Internet applications, it is used for below 3 things primarily:

  • Route end users to your site reliably with globally dispersed Domain Name System (DNS) servers and automatic scaling.
  • Set up your DNS routing in minutes with domain name registration and straightforward visual traffic flow tools.
  • Customize your DNS routing policies to reduce latency, improve application availability, and maintain compliance.

How Does It Work?

AWS Route53 is a highly available DNS service and scalale service, it working model is as shown below.

Let’s take an example, client accessed some site URL www.mysite.in in the browser

  • End user requests the URL in the browser
  • DNS Resolver resolves the domain
  • ROute53 returns the IP Address for the record
  • From the IP address received browser will show the User interface

Key Features of Route53

Before diving into the steps let’s discuss the key features of route53 and its advantages over other DNS hosting possibilities.

Global Network Infrastructure

Route 53 operates on a global anycast network, ensuring low latency and high-performance DNS resolution worldwide.

Advanced Routing Policies

Provides advanced routing policies such as weighted routing, latency-based routing, and geolocation-based routing, allowing sophisticated traffic management strategies.

Health Checks

Supports health checks to monitor resource health. In case of an unhealthy resource, we can configure Route 53 can automatically redirect traffic to healthy alternatives, ensuring high availability.

Easy to use Manage

AWS Route53 provides a user-friendly management console for configuring DNS settings, we can also use optional methods like AWS CLI or SDKs.

Pricing

It provides transparent and cost-effective pricing based on actual usage, with users paying for hosted zones and DNS queries, making it a cost-efficient choice.

Integration with AWS Services

Seamlessly integrates with various AWS services for easy management of DNS records tied to resources like S3 buckets, and Elastic Load Balancers.

Features like S3-Website won’t be supported by other DNS hosting providers, as this is an in-house feature.

Steps to Configure Route53

To configure our domain with AWS route53, we have the following steps:
Creating Hostzone in AWS Route53

  1. Sign in to AWS Console
  2. Create HostedZone
  3. Integrating Route53 with Domain Registrar
  4. Creating DNS records

Let’s go for setting up.

Step 1: Sign in to the AWS Management Console

Open Route53 in AWS Console by visiting “https://us-east-1.console.aws.amazon.com/route53/v2/hostedzones#”

From this page we can create hostedzones and manage them to add/update records.

route53-page

Route53 Home page

Step 2: Create Hostedzone in Route53

You can think of this hosted zone as a directory, it represents a collection of records that can be managed together, belonging to a single parent domain name.Create a hosted zone with the same name as your domain and then create records in the hosted zone to tell Amazon Route 53 how to route traffic.

  • Click on Create Host Zone.
  • Fill the Hosted Zone details as mentioned below
    • Domain Name: Your owned Domain Name (if not exists you can buy one from Route53 itself)
    • Description: Readable text to identify the domain
    • Type: Choose public if you wanna route traffic on the internet, and private if you wanna route traffic inside AWS VPC.

Create AWS Route53, Hosted Zone

Step 3: Integrating Route53 with Domain Registrar

You can find your route53 nameservers on the hosted zone page, copy all 4 nameservers, and update them on the Domain registrar website.

Update Name servers in Domain Registrar

Step 4: Creating DNS Records.

After opening the Hosted Zones Page, click on Create Record, and fill in the record details as mentioned below:

Create DNS Record in AWS Route53

  • Record Name: Domain/subdomain for the record
  • Record Type: Choose the type of the record based on your use case, here are the record types used often.

Record Type

Description

A

Routes traffic to an IPv4 address and some AWS resources

Choose when routing traffic to AWS resources for EC2, API Gateway, Amazon VPC, CloudFront, Elastic Beanstalk, ELB, or S3. For example: 192.0.2.44.

AAAA

Routes traffic to an IPv6 address and some AWS resources

Choose when routing traffic to CloudFront distributions (when IPv6 is enabled) or ELB load balancers. For example 2001:0db8::8a2e:0370:bab5.

CNAME

Routes traffic to another domain name and to some AWS resources

Choose when routing traffic to some Elastic Beanstalk environments or to Amazon RDS database instances.

MX

Specifies mail servers

Choose to specify the domain names of your mail servers. For multiple servers, you can also specify a priority for each one.

TXT

Used to verify email senders and for application-specific values

Choose instead of SPF, or when you want Route 53 to return application-specific values.

  • Alias: If you wanna create a record as an alias of existing AWS-supported resources like Cloudfront endpoint, S3 Website, and EC2 Instance, then you can check this option and choose the appropriate endpoint in sub-options.
  • Value: Value of the destination to route traffic to, for example, if you choose routing type A, the value is IP Address, for CNAME it’s domain URL
  • TTL: The amount of time, in seconds, that you want DNS recursive resolvers to cache information about this record, the ideal time would be 300.

TTL reflects the time to reflect the changes (a new ip address, a new domain in value), so client will get updated destination after specified TTL

Routing Policy

  • Choose simple if you want default routing, or if you’ve any specific use case like location-based routing or IP Address-based routing then choose the appropriate one.
  • After filling in all the details, click on Create records, wait for 2 minutes at least, and access your domain/subdomain to check if the specified record deployed.

Step 5: Testing DNS Records

We can check the website URL once the created record updated to status “INSYNC”

r53-status-(1)

Working with Amazon Route 53’s APIs

You can use the AWS SDKs and CDKs to create/update DNS records, by using them you can programmatically create records, update records, and check the status of the record, for instance if you’re comfortable with python programming language you can use boto3 for this.

Conclusion

In this article we’ve learnt what is Route53, key features in it, and also we’ve learnt hostedzones creation, adding & managing records for our websites, if you’ve any doubts let me know in the discussion tab, Happy routing.

Amazon Route 53 – FAQs

1. Where should I update the Nameservers?

It will change based on the domain registrar, for example for GoDaddy these are the steps, and if you’re using AWS Route53’s Domain then these are the steps.It might take upto 48 hrs in some cases to reflect the updated nameservers to come in effect.

2. Why should I update Nameservers at Registrar?

Basically, when a request is made to the TLD (Top Level Domain), the domain registrar will return the current nameservers to which the request is forwarded,

When you create a hosted zone in Amazon Route 53, you are essentially telling AWS that Route 53 is now responsible for managing the DNS records for your domain. However, for this delegation to take effect and for Route 53 to be recognized as the authoritative DNS service for your domain, you need to update the name servers at your domain registrar.

After a request is made to the TLD nameserver, the Amazon nameserver that hosts your records will be returned. This allows users to resolve the domain for your website or application.Don’t create additional name server (NS) or start of authority (SOA) records, and don’t delete the existing NS and SOA records.



Like Article
Suggest improvement
Share your thoughts in the comments

Similar Reads