How do I attach an Elastic IP address to new or existing internet-facing Network Load Balancers?

Last updated: 2020-03-26

How do I attach an Elastic IP address to new or existing public, internet-facing Network Load Balancers?

Resolution

Attach an Elastic IP address to a new Network Load Balancer

  1. Open the Amazon Elastic Compute Cloud (Amazon EC2) console.
  2. Choose the Region where you want to create your Network Load Balancer.
  3. Allocate Elastic IP addresses for your Network Load Balancer.
    Note: Be sure to create the same number of Elastic IP addresses as the number of subnets that you select in each Availability Zone. For more information about Elastic IP address quotas, see Elastic IP Address Limit.
  4. Under Load Balancing, choose Load Balancers.
  5. Choose Create Load Balancer.
  6. For Network Load Balancer, choose Create.
  7. Select the VPC in which you plan to provision the Network Load Balancer.
  8. Select the check box for the desired Availability Zone. Then, select the subnet in that Availability Zone.
  9. By default, the Network Load Balancer assigns a public IP address. If you want to use an Elastic IP address:
    For IPv4 address, choose Choose an Elastic IP.
    Select one of the Elastic IP addresses available in the specified Region. This IP address will be assigned to the Network Load Balancer's interfaces.
  10. (Optional) If you have multiple Availability Zones, repeat steps 8-9 for each zone.
  11. Complete the remaining steps for creating a Network Load Balancer.

Attach an Elastic IP address to an existing Network Load Balancer

Before you begin, be sure that you have the Elastic IP addresses for the Network Load Balancer elastic network interfaces so that you can directly assign them.

Note: After you enable a subnet in an Availability Zone, you can't modify the setting. Only new Availability Zones or subnets can be added. Elastic IP addresses can be set for new Availability Zones when you edit the settings.

  1. Open the Amazon EC2 console.
  2. Choose the Region in which your Network Load Balancer is located.
  3. Under Load Balancing, choose Load Balancers.
  4. Select your Network Load Balancer.
  5. Choose Actions, and then choose Edit Subnets.
  6. Select the desired Availability Zone.
  7. In the drop-down list, select the subnet in the Availability Zone.
  8. For IPv4 address, choose Choose an Elastic IP. A drop-down list containing each of the Elastic IPs in the specified Region appears.
  9. In the drop-down list, choose an IP address for this subnet. This IP address will be assigned to the Network Load Balancer’s interfaces.
  10. (Optional) If you have multiple Availability Zones, repeat steps 6-9 for each zone.
  11. Choose Save. An elastic network interface is created in the subnets you specified.

(Optional) Confirm that you've correctly configured your Elastic IP address attachments

  1. In the Amazon EC2 console, confirm that your Elastic IP addresses were successfully created.
  2. Cross-check the Elastic IP addresses found in step 1 against your Network Load Balancer interface:
    Open the Amazon EC2 console.
    Under Network & Security, choose Network Interfaces.
    In the filter section, enter the name of your Network Load Balancer.
    Review the list of the Network Load Balancer's elastic network interfaces. Confirm that the IP addresses for the elastic network interfaces match the Elastic IP addresses in the IPv4 Public IP column.

Did this article help you?

Anything we could improve?


Need more help?