EC2. Load balancer. At least two subnets must be specified

Dmitry Grinko picture Dmitry Grinko · Sep 13, 2018 · Viewed 10.8k times · Source

I'm trying to create and configure Load Balancer. The Availability Zones section has only one subnet and one zone for me.

I faced error:

At least two subnets must be specified.

Simple question - what should I do? thanks.

Answer

dmulter picture dmulter · Sep 13, 2018

You'll first need to create two or more subnets in your VPC. It's typically good practice to create at least one subnet for each availability zone (AZ) in your region. Be sure to select public/private as is appropriate for your architecture.

There isn't a specific example in the AWS documentation, but be sure to first understand VPC concepts and the creation of subnets. See Scenarios and Examples for the closest example walkthroughs for creating subnets.

Selecting subnets when configuring an ELB should be straightforward now.