This lab walks you through the steps to create an ELB and store ELB access logs in an S3 Bucket.
In this lab, you will create two EC2 instances and attach them to an elastic load balancer.
You will also enable Access logs in ELB and configure the ELB to send the logs to an S3 Bucket.
Duration: 1 hour
AWS Region: US East (N. Virginia) us-east-1
Load Balancer is a service that allows you to distribute incoming application or network traffic across multiple targets, such as Amazon EC2 instances, containers, and IP addresses across multiple Availability Zones.
AWS currently offers three types of load balancers:
Application Load Balancer
Network Load Balancer
Network Load Balancer is used to distribute the traffic or load using TCP/UDP protocols.
Classic Load Balancer provides basic load balancing across multiple Amazon EC2 instances.
ELB access logs provide detailed information regarding the request received by the load balancer.
Log files contain detailed information such as the time of the request, IP Address of the client, path of the request and the response from the server.
ELB access log feature is an optional feature.
You can use these access logs to analyze traffic patterns and troubleshoot issues.
Log files stored in S3 bucket are encrypted with a unique key.
There is no additional charge for access logs. You are charged storage costs in S3, but you are not charged for the bandwidth used by Elastic Load Balancing to send log files to Amazon S3.
When managing multiple environments, it would be better to store the logs in separate S3 buckets so that it will be easy to find logs for a specific environments.
Launching two web servers with apache service installed
Launching Elastic load balancer by attaching the web servers and enabling the s3 access log feature at the time of creating the load balancer
Testing the load balancer