zoukankan      html  css  js  c++  java
  • [AWS] EC2

    Let's have a look at how to create a load balancer, and see the configuration details for an existing load balancer.

    A. Prerequisite

    Go to the EC2 dashboard. In order to use elastic load balancing, you will need to make sure that you've launched the EC2 instances that you plan to register with your load balancer.

    You must have more than one EC2 instance in the running state. In our example snapshot below, we have two instances, in two different availability zones (AZs).

    Snapshot: Two servers, in different AZs, hosting the same application.

    B. Start the Load Balancer service

    On the EC2 dashboard, select the Load Balancers service from the navigation pane on left. Here, you can view the list and details of existing load balancers.

    Snapshot: Load Balancers

    Launch the Create Load Balancer wizard. AWS offers three types of load balancers, as shown below.

    Snapshot: Three types of load balancers.

    1. Application Load Balancer (ALB)
      A simple use case: Assume you are running a microservices-architecture based application. An Application Load Balancer allows you to host the different API endpoints of your application on different servers. The load balancer then redirects the incoming HTTP/HTTP traffic to the suitable server based on the rules you specify in the configuration.

      If you choose this option, you will be taken to a six-step process:

      1. Configure Load Balancer
      2. Configure Security Settings
      3. Configure Security Groups
      4. Configure Routing
      5. Register Targets
      6. Review
    1. Network Load Balancer (NLB)
      Network Load Balancer helps to balance the load on each individual server. Having an NLB becomes essential when your application requires handling millions of requests per second securely while maintaining ultra-low latencies.

      This option has a five-step process:

      1. Configure Load Balancer
      2. Configure Security Settings
      3. Configure Routing
      4. Register Targets
      5. Review

      See an example NLB below:

    Snapshot: An NLB balancing the load within a Target Group of instances

    1. Classic Load Balancer (CLB)
      It is a previous generation option. You can choose a Classic Load Balancer when you have an existing application running in the EC2-Classic network. You will have to follow a seven-step process to create a CLB:

      1. Define Load Balancer
      2. Assign Security Groups
      3. Configure Security Settings
      4. Configure Health Check
      5. Add EC2 Instances
      6. Add Tags
      7. Review

      See an example CLB below:

    Snapshot: A classic load balancer

    The CLB in the snapshot above is balancing the load between two of our EC2 instances: Server_1 and Server_2. If you click on the Instances tab, you're able to see the two instances that this load balancer is managing. You have the option to add or remove instances simply by clicking on Edit instances.

  • 相关阅读:
    深度学习(dropout)
    centos 常见软件安装
    最近读的书 与论文
    如何理解反向传播 Backpropagation 梯度下降算法要点
    ubuntu 15 安装cuda,开启GPU加速
    快速排序算法
    Linux网络中接收 "二进制" 流的那些事 --- 就recv的返回值和strlen库函数进行对话
    linux源码升级编译内核
    C/C++中慎用宏(#define)
    Qt之hello world
  • 原文地址:https://www.cnblogs.com/Answer1215/p/14543780.html
Copyright © 2011-2022 走看看