Skip to main content
Launch this lab in the IP Lab Portal, then follow the steps below in the AWS console. Open IP Lab Portal

Overview

Lab details

  1. The objective of this lab is to generate a Cost and Usage Report and storing it in an S3 bucket lies in understanding and managing the costs associated with AWS services effectively.
  2. Duration: 1 Hour
  3. AWS Region: US East (N. Virginia) us-east-1

Introduction

AWS Cost and Usage Report

  1. Cost and Usage Reports provide detailed information about your AWS usage and associated costs. This includes data on the usage of various AWS services, such as EC2 instances, S3 storage, RDS databases, etc., along with the corresponding costs incurred.
  2. The reports offer granular usage data, typically aggregated by the hour, day, or month, depending on your chosen time granularity. This level of detail allows users to analyze their AWS spending patterns over different time periods and identify trends or anomalies.
  3. Users can customize the Cost and Usage Reports based on their specific requirements. They can choose which additional content to include in the reports, such as resource IDs, split cost allocation data (for shared resources like Amazon ECS), and enable integration with services like Amazon Athena, Redshift, or QuickSight for further analysis.
  4. By analyzing the Cost and Usage Reports, users can gain insights into their AWS spending and identify opportunities for cost optimization. This may involve identifying unused or underutilized resources, optimizing instance types, leveraging Reserved Instances or Spot Instances, or implementing cost-saving strategies like rightsizing and scheduling.
  5. Cost and Usage Reports promote transparency and accountability in AWS spending. They provide stakeholders with visibility into resource usage, costs, and utilization across different departments, teams, or projects. This transparency helps in allocating costs accurately, tracking budget adherence, and facilitating financial planning and reporting processes.

Architecture diagram

Task details

  1. Sign in to AWS Management Console
  2. Create Cost and Usage report
  3. Validation of the Lab

Launching the lab environment

  1. To launch the lab environment, Click on the Launch lab button.
  2. Please wait until the cloud environment is provisioned. It will take less than a minute to provision.
  3. Once the lab is started, you will be provided with IAM user name, Password, Access Key, and Secret Access Key.
You can only start one lab at any given time

Lab guide

Lab steps

Task 1: Sign in to AWS Management Console

  1. Click on the Open console button, and you will get redirected to AWS Console in a new browser tab.
  2. On the AWS sign-in page,
    • Leave the Account ID as default. Never edit/remove the 12 digit Account ID present in the AWS Console. otherwise, you cannot proceed with the lab.
    • Now copy your User Name and Password in the lab Console to the IAM Username and Password in AWS Console and click on the Sign in button.
  3. Once Signed In to the AWS Management Console, Make the default AWS Region as US East (N. Virginia) us-east-1.

Task 2: Creating Cost and usage Report

  1. Navigate to Billing and Cost Management by clicking on the Services menu at the top, then click on Billing and Cost Management in the Cloud Financial Management section.
  2. Make sure you are in the US East (N. Virginia) us-east-1 Region.
  3. In the Billing and Cost Management Click on Data Exports in the left panel and click on Create button.
  1. Export Type : Select Standard data report
  2. Export Name: Enter WhizReport
  3. For Data table content settings:
  • Keep resource IDs and Split cost allocation data as uncheck for now as they creates individual line items for each of your resources. This might increase the size of your Cost and Usage Reports files significantly, based on your AWS usage.
  • Time granularity: Select Hourly
  1. Keep Data export delivery options as default.
  2. For Data export storage settings :
  • To create S3 bucket click on configure button.
  • Select Create a bucket
  • Bucket name : Enter whizbucket<RANDOM_NUMBERS>
  • Click on Create bucket button.
  • S3 path prefix: Enter Report
  1. Click on Create button to create the report.
  1. Your Cost Report is created and it will be stored in S3 bucket after 24 hours.
This lab is developed to show how to store cost reports in an S3 bucket. AWS policy states that it can take up to 24 hours for reports to start appearing in the S3 bucket. Therefore, this lab will only last 1 hour, which means we can’t not be able to access the actual report during this time.
Do you know?AWS Cost and Usage Reports not only facilitate cost optimization but also foster a culture of financial stewardship and accountability, ultimately contributing to the long-term success and sustainability of businesses operating in the cloud.

Task 3: Validation of the Lab

  1. Once the lab steps are completed, please click on the Check my work button on the Right side panel.
  2. This will validate the resources in the AWS account and displays whether you have completed this lab successfully or not.
  3. Sample output :

Completion and conclusion

  1. You have successfully created cost usage report

End lab

  1. Sign out of AWS Account.
  2. You have successfully completed the lab.
  3. Once you have completed the steps, click on End lab in the IP Lab Portal.

What gets checked

When you press Check my work, the platform verifies each of these:
  • Check whether a data export report is created with HEALTHY state or not — Check whether a data export report is created with HEALTHY state or not
  • check s3 object — Check whether an object is uploaded to the S3 bucket.