AWS Load Balancing, File Migration

It distributes incoming application traffic across multiple targets

πŸ’‘
Load Balancer only has DNS. It doesn’t have IP Address


Creating and Connecting to EC2 instances (2)

  1. Creating two Amazon Linux Instance
  1. Select a machine β†’ Click connect β†’ Copy given example β†’ write in git bash
  1. Install httpd web server
    yum install httpd
  1. Check status of server
    systemctl status
    systemctl start httpd
  1. Go to www directory and change index.html
    cd /var/www/html/
    echo "This is First Server" > index.html
  1. DO THE SAME FOR SECOND SERVER

Load Balancing

Create group and attach machines to it

  1. Load Balancing β†’ Target Groups β†’ Create target groups
  1. Target type: Instances
  1. Give Target group name, Protocol, IP address type, VPC, Protocol version
  1. Configure Health Check settings
  1. Select both servers and click Include as pending below β†’ Create Target Group

Creating Load Balancers

Types of Load Balancer:

  • Application - works on layer 7
  • Network - works on layer 3
  • Gateway
  • Classic

Steps:

  • Click on load balancer in side bar β†’ create load balancer
  • Application Load Balancer β†’ Name it β†’ Network Mapping β†’ Security Groups β†’ Listeners and routing β†’ Summary β†’ Create Load Balancer
  • Check health of machines

File Migration

Same can be done for images, pdfs