hands-on lab

Monitoring Amazon CloudWatch Log Group Sizes

Beginner
1h
192
5/5
Get guided in a real environmentPractice with a step-by-step scenario in a real, provisioned environment.
Learn and validateUse validations to check your solutions every step of the way.
See resultsTrack your knowledge and monitor your progress.
Lab description

Amazon CloudWatch Logs can be used to capture logging data sent from various sources such as Amazon EC2 instances, Lambda Functions, custom applications, and many more.

When using CloudWatch Logs, its important to monitor log growth. Unchecked and uncontrolled log growth can be a surprise line item in your monthly cloud bill.

In this hands-on lab, you'll learn how to build a custom CloudWatch dashboard and metric that displays the size of each CloudWatch Log group discovered within your lab account. To demonstrate this objective, the lab starts up with 2 basic Lambda Functions configured to trigger each minute. You'll be required to review and update each Lambda Function, updating their implementations with provided code. What the Lambda Functions do is not important, what is important is the fact that their implementations involve logging out different amounts of data to CloudWatch.

Learning Objectives

Upon completion of this beginner-level lab, you will be able to:

  • Create a custom CloudWatch dashboard
  • Define a custom CloudWatch metric that calculates the total size of each CloudWatch Log group
  • Define a custom CloudWatch metric that auto detects CloudWatch Log groups in the current account
  • Review and update a Lambda Function to log out data to CloudWatch
  • Navigate to and review the contents of each CloudWatch Log group

Intended Audience

  • Cloud Architects
  • Software Engineers
  • FinOps Practitioners

Prerequisites

Familiarity with the following will be beneficial but is not required:

  • Amazon CloudWatch
  • AWS Lambda

The following content can be used to fulfill the prerequisite:

Environment before
Environment after
About the author
Avatar
Jeremy Cook
Content Lead Architect
Students
159,312
Labs
80
Courses
108
Learning paths
212

Jeremy is a Content Lead Architect and DevOps SME here at Cloud Academy where he specializes in developing DevOps technical training documentation.

He has a strong background in software engineering, and has been coding with various languages, frameworks, and systems for the past 25+ years. In recent times, Jeremy has been focused on DevOps, Cloud (AWS, Azure, GCP), Security, Kubernetes, and Machine Learning.

Jeremy holds professional certifications for AWS, Azure, GCP, Terraform, Kubernetes (CKA, CKAD, CKS).

Covered topics
Lab steps
Logging In to the Amazon Web Services Console
Review and Update Provided Lambda Functions
Examine the CloudWatch Log Groups
Create a CloudWatch Dashboard and Add a Custom Metric to Monitor Log Group Sizes