1. Home
  2. Training Library
  3. Alibaba Cloud
  4. Courses
  5. Alibaba Server Load Balancer (SLB)

High Availability

Developed with
QA

The course is part of this learning path

play-arrow
Start course
Overview
DifficultyBeginner
Duration37m
Students43
Ratings
5/5
starstarstarstarstar

Description

This course provides an introduction to Alibaba's Server Load Balancer service, also known as SLB. The course begins with a brief intro to load balancing in general and then takes a look at Alibaba SLB and its three main components. We'll look at how SLB can be used for high availability, fault tolerance, and disaster tolerance. You will also learn about SLB instance clusters, traffic routing, and security, before finally moving on to a demonstration from the Alibaba Cloud platform that shows how to set up a Server Load Balancer with two servers.

If you have any feedback relating to this course, please get in touch with us at support@cloudacademy.com.

Learning Objectives

  • Learn about load balancing and Alibaba's Server Load Balancer (SLB) service
  • Understand the three main components of SLB
  • Learn about high availability and fault tolerance with Alibaba SLB
  • Learn about the running and operations of SLB
  • Set up a Server Load Balancer

Intended Audience

This course is intended for anyone who wants to learn about the basics of Alibaba's Server Load Balancer service and how to use it.

Prerequisites

To get the most out of this course, you should have a basic understanding of Alibaba Cloud. Some knowledge of load balancing would also be beneficial.

Transcript

Welcome to session three, SLB high availability. In this session, we will look at the following topics. Provisioning high availability of SLB in a single zone, provisioning high availability of SLB in multiple zones, and provisioning cross-region disaster tolerance of SLB.

Provisioning high availability of SLB in a single zone. In session one, an introduction to load balancing, I talked about the reasoning behind providing multiple backend servers when providing a web service. Basically, it was to prevent a single point of failure by spreading the service across multiple web servers, and at the same time, providing a request balancing service so that one web server doesn't become overloaded with requests. In essence, we're providing a highly available service by utilizing multiple servers. Whilst everything is okay, a normal service is achieved.

High availability in a single zone is achieved by health checks. If the hardware that a server resides on fails, then SLB detects that the server is no longer available due to the health checks that are carried out on the listener in the SLB. However, by placing all of the servers in the same zone, we are now introducing another point of failure, and that is failure at the zone level. If the zone itself fails, then we lose all backend servers and the load balancer itself.

Provisioning high availability of SLB in multiple zones. To overcome the problem of a single zone failure, Alibaba automatically provisions a backup server load balancer in another zone, but in the same region. One zone is set up as the primary zone and another as the backup zone. This is known as a multi-zone SLB. When you create the SLB instance, you can choose which zone is the primary zone and which is the backup zone. At the time of this recording, there are 21 regions available for the provisioning of a server load balancer solution, and currently the UAE region is the only one with a single zone and therefore does not support multi-zone. All other regions by default are multi-zone regions.

Recommended best practice is to provision a server load balancer in a region that supports multi-zones, thereby leveraging automatic high availability across two zones in the same region. To achieve this, you will have to provision at least one backend server in the backup zone. If you have at least two servers in each zone, you will then have high availability at the zone level and at the region level. While the service is running and both zones are in a healthy state, traffic is distributed across all backend servers based on the rules applied to the listeners. If a failure occurs at the primary zone level, SLB will detect the zone failure and within 30 seconds switch to the backup SLB instance to keep the service running. If the primary zone is up but the backup zone becomes unavailable, the health check on the listeners will detect the backend servers are not responding and stop sending traffic to them. When the primary region becomes available again, SLB switches back and normal service resumes.

Provisioning cross-region disaster tolerance of SLB. The SLB service spans across two zones in a region for high availability, but a single SLB instance cannot span across multiple regions. To protect against a complete regional failure, you can configure multiple SLB instances in different regions. You can then use Alibaba's cloud DNS service to schedule requests to achieve cross-region disaster tolerance through global SLB. You can use DNS to resolve domain names to the IP addresses of multiple SLB instances running in different regions. In the event of a region outage, DNS can then stop DNS resolution for the effective domain, thereby creating cross-region disaster tolerance by still being able to forward traffic to the second region's server load balancer.

So let's recap. SLB is a fully managed, scalable, and highly available load balancing service. Its content-based routing using listeners allows requests to be routed to different applications behind a single load balancer, thereby saving the cost of having to build a web server per application. By utilizing the multi-zone feature for SLB, it supports multi-zone disaster tolerance. If the primary zone becomes unavailable, SLB rapidly switches to the backup zone. And it can support multi-region disaster tolerance when used in conjunction with DNS. That concludes this session on SLB high availability.

In the next session, I will be covering server load balancer architecture. I look forward to speaking to you in the next session.

About the Author
Students2645
Labs19
Courses20
Learning paths22

QA is the UK's biggest training provider of virtual and online classes in technology, project management and leadership.