How to Create Egress-only internet gateway & DHCP option set on Amazon Web Services(AWS).

An egress-only internet gateway is a horizontally scaled, redundant, and highly available VPC component that allows outbound communication over IPv6 from instances in your VPC to the internet, and prevents the internet from initiating an IPv6 connection with your instances.

Egress-only Internet gateway works as a NAT gateway, but for IPv6 traffic. An egress-only Internet gateway is for use with IPv6 traffic only. To enable outbound-only Internet communication over IPv4, use a NAT gateway instead.

 

  • Login to aws portal.
  • Click on Services.

 

Fig 1

 

  • Under Networking & Content Delivery select VPC.

 

Fig. 3

 

  • Click on Egress-only internet gateways.

 

Fig. 3

 

  • Click on Create egress-only internet gateway.

 

Fig. 4

 

  • Provide Egress-only internet gateway tag name.
  • Select existing VPC.
  • Click on Create.

 

Fig. 5

 

  • After sometime Egress-only internet gateway is ready.

 

Fig. 6

 

DHCP option sets

DHCP is a network protocol that dynamically assigns IP addresses to instances in a VPC from the respective subnet’s CIDR block. It also passes configuration information such as domain name, Domain Name Server (DNS), NTP server, and so on. This configuration information is called a DHCP option set.

AWS recommends that you create a DHCP options set for your AWS Directory Service directory and assign the DHCP options set to the VPC that your directory is in. This allows any instances in that VPC to point to the specified domain and DNS servers to resolve their domain names.

 

  • Click on DHCP options sets.

 

Fig. 7

 

  • Click on Create Create DHCP option set.

 

Fig. 8

 

  • Provide DHCP option set tag name.
  • Provide Domain name.
  • Provide DNS server ip & NTP server IP otherwise leave this field blank.

 

Fig 9

 

  • Provide NetBios name servers & node type otherwise leave this field blank.
  • click on create dhcp option set.

 

Fig 10

 

  • After sometime DHCP option set is ready.

 

Fig 11

 

Create Egress-only internet gateway & DHCP options set using Shell

To create an egress-only Internet gateway

aws ec2 create-egress-only-internet-gateway –vpc-id vpc-id

To create a set of DHCP options

aws ec2 create-dhcp-options  –dhcp-configuration  “Key=domain-name-servers,Values=10.0.1.1,10.0.1.2” “Key=domain-name,Values=example.com”  “Key=netbios-node-type,Values=2”

 

Leave a Reply

Your email address will not be published.