Load Balancer
⏱️ Estimated reading time: 2 minutes
What is a Load Balancer?
A Load Balancer is a network service that distributes incoming traffic across multiple virtual machines (VMs) to ensure optimal resource utilization, improve application availability, and maintain high performance.
By balancing the workload, Load Balancers help:
- Prevent server overload
- Improve application reliability
- Provide redundancy in case one or more servers go down
They are especially beneficial for high-traffic applications, as they maintain smooth and efficient operations even under load.
Creating a Load Balancer
To set up a Load Balancer using the Webberstop Cloud Portal, follow these steps:
-
Log in to the portal.
-
From the sidebar, go to Load Balancer.
-
Click the ➕ plus icon at the top right to begin the creation process.
Step-by-Step Configuration
1. Select Project
Choose the project under which the Load Balancer will be created.
2. Select Datacenter Location
Pick the zone or region where the Load Balancer should reside.
3. Select Network
Choose the network (VPC, Isolated, or Shared) associated with the Load Balancer.
4. Assign Public IP
- Acquire a new public IP, or
- Select from existing available IPs in your project.
5. Configure Forwarding Rules
Fill in the following details to define how incoming traffic will be handled:
- Name: A descriptive name for the load balancing rule.
- Protocol: Choose protocol from TCP/ UDP/ TCP Proxy
- Public Port: The external port where traffic will be received (e.g., 80, 443).
- Private Port: The internal port used by backend VMs (e.g., 8080).
- Algorithm: Select from:
- Round Robin: Distributes traffic evenly across all VMs.
- Least Connections: Sends traffic to the VM with the fewest active connections.
- Source: Uses source IP hashing to ensure session consistency.
6. Stickiness (Optional)
Enable and choose a stickiness policy if you want requests from the same user/session to consistently reach the same VM.
7. Add Virtual Machines
Select two or more backend VMs to associate with the load balancing rule. Click Apply to confirm.
You can repeat this process to configure additional rules under the same Load Balancer IP.
Final Step
- Set a Name for the Load Balancer instance.
- Choose a Billing Cycle: Hourly, Monthly, or Yearly.
- Click Review & Deploy to complete the setup.
Need high availability? Consider placing backend VMs across different availability zones to ensure redundancy and uptime.