How to Create NAT gateway & Network ACL on Amazon Web Service(AWS).

NAT Gateway is a highly available AWS managed service that makes it easy to connect to the Internet from instances within a private subnet in an Amazon Virtual Private Cloud (Amazon VPC). Previously, you needed to launch a NAT instance to enable NAT for instances in a private subnet.

A network access control list (ACL) is an optional layer of security for your VPC that acts as a firewall for controlling traffic in and out of one or more subnets. You might set up network ACLs with rules similar to your security groups in order to add an additional layer of security to your VPC.

 

NAT Gateway

  • Login to aws portal.
  • Click on Services.

 

Fig 1

 

  • Under Networking & Content Delivery select VPC.

 

Fig 2

 

  • Click on NAT Gateways.

 

Fig. 3

 

  • Click on Create NAT gateway.

 

Fig. 4

 

  • Provide NAT gateway tag name.
  • Select existing subnet.
  • Click on Allocate Elastic IP.Assign a elastic IP to nat gateway.

Fig. 5

 

  • Click on Create nat gateway.

 

Fig. 6

 

  • After sometime NAT gateway is ready.

 

Fig. 7

 

 

Network ACL

  • Click on Network ACLs.

 

Fig. 8

 

  • Provide Network ACL tag name.
  • Select existing VPC.
  • Click on Create Network ACL.

 

Fig 9

 

  • After sometime Network ACL is ready.

 

Fig 10

 

Create NAT Gateway & Network ACL using Shell

To create a NAT gateway

aws ec2 create-nat-gateway –subnet-id subnet-id –allocation-id elastic-ip-id

To create a network ACL

aws ec2 create-network-acl –vpc-id vpc-id

 

 

Leave a Reply