Create a Load Balancer
A Load Balancer distributes incoming traffic across multiple backend instances, improving the availability, scalability, and reliability of your applications.
This article explains how to create a Load Balancer, the required network configuration, and the available deployment options.
Prerequisites
Before creating a Load Balancer, ensure that:
- You have an existing project.
- You have created a Network.
- The Network contains at least one Subnet.
- Your instances are connected to the same Network
Note: A Load Balancer cannot be created without an existing subnet.
Network Requirements
- A Load Balancer must be attached to a Subnet within a Network.
- During the creation process, you will be asked to select an existing subnet.
- The Load Balancer is created on the selected subnet and is used to route traffic to backend instances.
- If you do not already have a network, complete the following steps first:
- Create a Network.
- Create a Subnet within the network.
- Connect your backend instances to the subnet.
Public Connectivity
A Network by itself does not provide connectivity to the public Internet. If you want your application to be publicly accessible, the Network must be connected to a Router.
The router provides connectivity between your Network and the external network.
Without a Router, the Load Balancer is only reachable by resources connected to the same Network.
Create a Load Balancer
Launch wizard consists of the following configuration steps.
- Select a Region
- Select the region where the Load Balancer will be deployed.
- Select an Availability Zone
- Choose the Availability Zone where the Load Balancer will be deployed.
- AZ-01
- AZ-02
- A Load Balancer can currently distribute traffic only to backend instances located in the same Availability Zone. For example, a Load Balancer deployed in AZ-01 can balance traffic only to instances running in AZ-01.
- Choose the Availability Zone where the Load Balancer will be deployed.
- Select an Instance Type
- Choose the Load Balancer size that best matches your expected workload.
| Instance Type | vCPUs | Memory | Recommended For |
|---|---|---|---|
| lsw.lb.small | 1 | 1 GiB | Development, testing, internal applications, and low-traffic workloads. |
| lsw.lb.medium | 2 | 2 GiB | Production applications, APIs, and medium-traffic services. |
| lsw.lb.large | 4 | 4 GiB | High-traffic applications, enterprise workloads, and services requiring increased capacity. |
- Add a Name for your load balancer instance
- Add a Description for your load balancer instance (optional)
- Select a Subnet
- Select the subnet where the Load Balancer Virtual IP (VIP) will be created.
- Only subnets within the selected Availability Zone are available for selection.
- The selected subnet must be connected to the backend instances that will receive traffic.
Review and Create
Review the selected configuration:
- Region
- Availability Zone
- Subnet
- Instance Type
If everything is correct, click Create Load Balancer.
The Load Balancer will enter the Creating state while it is being provisioned.
Once provisioning is complete, the status changes to Active, indicating that the Load Balancer is ready to be configured.