Logo

dev-resources.site

for different kinds of informations.

How to Add an Elastic (Static) IP to Your EC2 Instance And Update Your DNS Records on Route53

Published at
12/5/2024
Categories
webdev
route53
beginners
dns
Author
ntombizakhona
Categories
4 categories in total
webdev
open
route53
open
beginners
open
dns
open
Author
13 person written this
ntombizakhona
open
How to Add an Elastic (Static) IP to Your EC2 Instance And Update Your DNS Records on Route53

Assigning an Elastic IP to Your EC2 Instance

Once your EC2 instance is up and running, the next step is to assign an Elastic IP address to it. This ensures your instance has a static public IP, which remains consistent even if the instance is stopped and started. This is crucial for maintaining a reliable connection to your application or website.


What is an Elastic IP?

An Elastic IP is a static IPv4 address designed for dynamic cloud computing. It allows you to associate a persistent IP address with your EC2 instance, enabling seamless connectivity without worrying about changing IP addresses.


Benefits of Using an Elastic IP:

  1. Static Public IP: Provides a fixed IP that won’t change, making it easy to set DNS records.
  2. High Availability: You can quickly remap the Elastic IP to another instance if needed, ensuring minimal downtime.
  3. Cost-Effective: It's free as long as it’s associated with a running instance.

Steps to Add an Elastic IP to Your EC2 Instance:

Allocate an Elastic IP

  1. Go to the EC2 Dashboard in the AWS Management Console.
  2. In the left-hand menu, select Elastic IPs.
  3. Click on Allocate Elastic IP address.
  4. Select Amazon's pool of IPv4 addresses.

Associate the Elastic IP with Your Instance

  1. Click Allocate.
  2. Click Associate this Elastic IP address.
  3. Choose Your Instance from the dropdown.
  4. Optionally, specify a private IP address if your instance has multiple private IPs.
  5. Click Associate

Update Your DNS Records

Once the Elastic IP is associated, update your DNS records in Route 53 to point your domain to the new Elastic IP.

  1. Go to the Route 53 dashboard.
  2. Select your hosted zone.
  3. Edit or create an A record to use the Elastic IP.

Verification:

To confirm everything is working:

  1. Open a browser and type your domain name.
  2. You should see your application or website resolving correctly.

Now that your EC2 instance has a static public IP, your application is better equipped for reliable and consistent access, and you can stop your instance, update your user data without losing your IP!

Check out: Student Analyst to observe the steps in this series.

dns Article's
30 articles in total
Favicon
Building and Deploying a New API (Part 3)
Favicon
Configuring a custom domain for your Azure Static Web App
Favicon
วิธีติดตั้งและกำหนดค่าเบื้องต้นสำหรับเซิร์ฟเวอร์ DNS บน Ubuntu 22.04 LTS แบบง่าย ๆ
Favicon
Email Verifier using Go
Favicon
What are DNS records?
Favicon
How to understand the ins and outs of how DNS really works.
Favicon
How to Simplify DNS Management in a Multi-Account Environment with Route 53 Resolver
Favicon
How to Add an Elastic (Static) IP to Your EC2 Instance And Update Your DNS Records on Route53
Favicon
DNS Spoofing: Controlling DNS Requests on the Network
Favicon
DHCP dinamik DNS güncellemesi
Favicon
Migrate a hosted zone to a different AWS account in few seconds!!
Favicon
Explaining DNS NXDOMAIN status in SOA Record Type: On Non-Existing Domains
Favicon
Instant Domain Insights: Why Every Tech Professional Needs DNS Checker Pro
Favicon
Automating DNS Management in Kubernetes with ExternalDNS
Favicon
DNS-load-balancing
Favicon
Verify your Bluesky or Mastodon account on your own domain, with a free website!
Favicon
How to Install and Configure a Private BIND DNS Server on Ubuntu 22.04
Favicon
How to Add DNS Records for Your Domain in Route53
Favicon
AWS S3 Change Url, Proxy Url, Map to Domain in 2024
Favicon
From WHOIS to SSL: How DNS Checker Pro Unveils the Hidden Details of Any Website
Favicon
Automating AWS DNS Firewall Domain List Updates Using S3, Lambda, and CLI
Favicon
Explaining CAA DNS Record
Favicon
Mastering DNS Spoofing with Bettercap: A Comprehensive Guide
Favicon
Issue 65 of AWS Cloud Security Weekly
Favicon
Unlocking the Internet's Address Book: DNS Roots Explained!
Favicon
I bought us-east-1.com: A Look at Security, DNS Traffic, and Protecting AWS Users
Favicon
Unlocking the Power of AWS Route 53: Your Complete Guide to DNS Management
Favicon
DNS: More Than Just a Web Directory
Favicon
Automating DNS with Confidence: Terraform + DNScontrol
Favicon
"Message Not Delivered" - What to Do When Your Email Bounces Back?

Featured ones: