Load Balancing Between Starter Package ECS Instances: Part 2

What Is Server Load Balancer?

- <strong>Listener Protocol</strong>: SLB supports HTTP, HTTPS, TCP, and UDP protocols.
- <strong>Listening Port</strong>: It is used to receive requests and forward it to backend servers.
- <strong>Port of Backend Servers</strong>: The port opened on the backend server to receive requests. It can be the same in an SLB instance.
- <strong>Weight of Backend Servers</strong>: An ECS instance with a higher weight value receives more requests. Setting the weight value to zero is equal to removing the ECS instance from Server Load Balancer.

Create SLB Instance

  • Region: Select the same region as your previously launched ECS instances. Since SLB service does not support cross-region deployment, make sure that the ECS instances and the SLB instances are in the same region.
  • Primary Zone: It carries traffic in normal conditions.
  • Instance Name: Enter a name for the SLB instance.
  • Backup Zone: If applicable, the secondary zone only takes over traffic when the primary zone is unavailable.
  • Instance Type: There are two types of instances. An Internet SLB instance provides a public IP address and can be accessed from the Internet. An intranet SLB instance provides a private IP address and can be only accessed from the intranet. In this tutorial, we will choose Internet Instance.
  • Instance Spec: Select a performance specification for your SLB instance. The performance varies by the specification. For a shared-performance instance, performance is not guaranteed and resources are shared by all instances. The other instances provide guaranteed performance metrics and are opposite to a shared-performance instance. There are three key performance metrics for guaranteed-performance SLB instances:
  1. Max Connection: The maximum number of connections to an SLB instance at a time.
  2. Connection Per Second (CPS): The maximum number of new connections that can be established per second.
  3. Query Per Second (QPS): The maximum number of HTTP/HTTPS requests that can be processed per second.
  • Anti-DDoS: Alibaba Cloud Anti-DDoS Basic is enabled by default while creating Server Load Balance instances and provides a 5 Gbps mitigation capacity free of charge. This service defends against various DDoS attacks, including but not limited to ICMP flood, UDP flood, TCP flood, SYN flood, and ACK flood attacks.
  • Bandwidth: The communications between ECS instances and SLB instances are through an internal network, and do not incur any traffic fees. For more information, refer to Network Traffic Flow. Traffic fees for SLB instances that use the Internet apply to outgoing traffic (downstream traffic) and no fees are charged for incoming traffic (upstream traffic).

Configure HTTP Traffic Forwarding on SLB Instance

Configure HTTPS Traffic Forwarding on SLB Instance

Redirect HTTP to HTTPS

Traffic Forwarding Based on Domain Names or URLs

yourdomain.com. IN A SLB_PUBLIC_IP
www.yourdomain.com. IN A SLB_PUBLIC_IP

Original Source



Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Alibaba Cloud

Alibaba Cloud

Follow me to keep abreast with the latest technology news, industry insights, and developer trends. Alibaba Cloud website:https://www.alibabacloud.com