Sign in

End-to-End AWS Cost Tracking and Management

There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

This runbook focuses on the end-to-end management of AWS costs, starting from the initial setup of CUR reports in S3 buckets to detailed tracking and analysis of these reports for effective cost control and insights.

  1. 1

    Verify whether a CUR report has been set up with the proper prerequisites

    There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

    This task checks for the existence of a specified S3 bucket and exports the names of CUR reports and base paths. If these do not exist, it automates the configuration of CUR reports, including S3 bucket creation, policy updates for cost data delivery, and CUR setup.

    1
    1. 1.1

      End to End Configuration of an AWS Cost And Usage Report(CUR) to a S3 Bucket

      There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

      This runbook provides a comprehensive guide for setting up and configuring AWS Cost and Usage Reports (CUR) to be delivered to an S3 bucket. It covers the process from creating a new S3 bucket, updating its policy for CUR compatibility, to configuring the CUR settings to target the created bucket.

      1.1
      1. 1.1.1

        Create a New AWS S3 Bucket

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

        This task involves creating a new Amazon S3 bucket in a specified AWS region. It's the initial step in setting up a destination for storing Cost and Usage Reports.

        1.1.1
      2. 1.1.2

        Update the AWS S3 Bucket Policy to Allow CUR Logging

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

        In this task, the S3 bucket's policy is updated to grant necessary permissions for AWS Cost and Usage Reports to deliver log files to the bucket, ensuring secure and compliant data storage.

        1.1.2
      3. 1.1.3

        Configure AWS Cost And Usage Report to a S3 Bucket

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

        This task involves configuring AWS Cost and Usage Reports (CUR) to direct the reports to the newly created and configured S3 bucket, finalizing the setup for report generation and storage.

        1.1.3
    2. 1.2

      CUR Integration using AWS Athena, S3, Glue

      There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

      This task involves setting up an integration to analyze AWS Cost and Usage Report (CUR) data using AWS Athena, storing the data in S3, and organizing it with AWS Glue Crawler.

      1.2
      1. 1.2.1

        Create CloudFormation Stack for Athena CUR Setup

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

        Develop a CloudFormation stack to automate the deployment of necessary resources for querying CUR data with Athena, ensuring all components are correctly configured and linked.

        1.2.1
      2. 1.2.2

        Verify whether the CloudFormation stack has been created

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

        Check if the specified CloudFormation stack is already present to avoid redundancy, ensuring that resources are managed efficiently without duplication.

        1.2.2
      3. 1.2.3

        Create s3 bucket to store athena cur query results and skip if it exists

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

        Establish an S3 bucket dedicated to storing results from Athena queries on CUR data; this process includes a check to skip creation if the bucket already exists.

        1.2.3
  2. 2

    Cost Tracking with AWS Cost and Usage Report (CUR)

    There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

    The AWS Cost and Usage Report (CUR) provides a comprehensive view of AWS expenses and resource utilization over a specified period. By analyzing the CUR, organizations can gain deep insights into their cloud spending patterns, identify cost drivers, and optimize their AWS resource utilization. This report allows for granular cost tracking by various dimensions, including services, regions and others enabling effective budgeting and forecasting.

    2
    1. 2.1

      Comprehensive AWS Cost Analysis Breakdown

      There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

      This task provides a comprehensive analysis of AWS expenses through five key modules. It categorizes costs by AWS services, identifies primary cost drivers and more. The analysis charts expenses over time and breaks down costs by AWS account IDs to pinpoint major spenders aiding in efficient financial forecasting and planning.

      2.1
      1. 2.1.1

        Daily AWS Costs using Athena

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

        Analyze daily AWS spending by querying the CUR data stored in S3 with Athena, providing insights into overall cost trends and spikes.

        2.1.1
      2. 2.1.2

        Daily AWS Costs by service using Athena

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

        Break down daily AWS expenses by service to pinpoint where spending is occurring, using Athena to query detailed CUR data.

        2.1.2
      3. 2.1.3

        EC2 Cost Analysis

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.
        2.1.3
        1. 2.1.3.1

          Daily AWS Costs by top_n_instances using athena

          There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

          Focus on the highest cost-generating instances, querying CUR data with Athena to identify and analyze the top spending instances daily.

          2.1.3.1
        2. 2.1.3.2

          AWS EC2 Usage Analysis

          There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

          This runbook involves collecting data on EC2 instances, retrieving CPU utilization metrics from Amazon CloudWatch, and visually plotting this data to identify underutilized or overutilized instances. This task helps in recognizing potential cost-saving opportunities by rightsizing instances, either by downsizing underutilized instances to reduce costs or upsizing overutilized instances to improve performance.

          2.1.3.2
          1. 2.1.3.2.1

            Get all AWS EC2 instances

            There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

            Amazon Elastic Compute Cloud (EC2) is a service offered by Amazon Web Services (AWS) that provides resizable compute capacity in the cloud. Through Boto3's EC2 client, the describe_instances() method provides detailed information about each instance, including its ID, type, launch time, and current state. This capability assists users in effectively monitoring and managing their cloud resources.

            2.1.3.2.1
          2. 2.1.3.2.2

            Aggregate and Visualize Comprehensive EC2 CPU Utilization

            There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

            This task aggregates CPU utilization data for running EC2 instances across an AWS account, computes the average CPU usage over a specified period, and plots the average to help in assessing overall resource efficiency.

            2.1.3.2.2
          3. 2.1.3.2.3

            Plot Average CPU Utilization for all running AWS EC2 Instances

            There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

            This task entails collecting CPU usage metrics from Amazon CloudWatch, calculating the average utilization, and visualizing this data. This task aids in identifying underutilized or overutilized instances, facilitating efficient resource management and cost optimization in AWS.

            2.1.3.2.3
        3. 2.1.3.3

          Rightsizing Recommendations for AWS EC2 Instances using AWS Compute Optimizer

          There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

          This task utilizes AWS Compute Optimizer to fetch rightsizing recommendations for AWS EC2 instances, aiming to optimize instance sizes based on actual usage. It assesses whether instances are under-utilized or over-utilized, suggesting adjustments to enhance performance and reduce costs. By querying across specified or all regions, it allows for a comprehensive optimization strategy, ensuring resources are efficiently allocated and maximizes cost-effectiveness and performance across your AWS environment.

          2.1.3.3
          1. 2.1.3.3.1

            Fetch Rightsizing Recommendations for AWS EC2 Instances

            There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

            This task retrieves AWS EC2 instance rightsizing recommendations using AWS Compute Optimizer, identifying cost-saving and performance-enhancing opportunities by analyzing usage patterns. It suggests optimal instance types or sizes, ensuring efficient resource utilization.

            2.1.3.3.1
          2. 2.1.3.3.2

            Plot Savings based on AWS EC2 Rightsizing Recommendations

            There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

            This task generates a bar chart visualizing AWS EC2 rightsizing savings, with instance names on the X-axis and different recommendations distinguished by instance ID and rank in the legend.

            2.1.3.3.2
      4. 2.1.4

        EBS Cost Analysis

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.
        2.1.4
        1. 2.1.4.1

          Rightsizing Recommendations for AWS EBS Volumes using AWS Compute Optimizer

          There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

          This runbook aids in enhancing storage efficiency by providing insights based on usage analysis. This service suggests optimal EBS volume configurations, including type, size, and IOPS, to align with performance needs and cost savings.

          2.1.4.1
          1. 2.1.4.1.1

            Fetch Rightsizing Recommendations for AWS EBS Volumes

            There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

            This task involves analyzing EBS volume usage to offer configuration changes for cost efficiency and performance improvement, based on historical data analysis.

            2.1.4.1.1
      5. 2.1.5

        RDS Cost Analysis

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.
        2.1.5
        1. 2.1.5.1

          Aggregate and Visualize Comprehensive RDS CPU Utilization

          There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

          This task aggregates CPU utilization data for running RDS instances across an AWS account, computes the average CPU usage over a specified period, and plots the average to help in assessing overall resource efficiency.

          2.1.5.1
        2. 2.1.5.2

          Daily AWS RDS Costs using Athena

          There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

          Specifically examine daily costs associated with AWS RDS, utilizing Athena to query CUR data for detailed spending analysis on database services.

          2.1.5.2
      6. 2.1.6

        AWS Costs per Linked Account using Athena

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

        Segment and analyze costs for each linked account under a consolidated billing setup using Athena to query CUR data, providing clarity on spending distribution across accounts.

        2.1.6
  3. 3

    Unused Underutilized Unattached Orphaned AWS Resources

    There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.
    3
    1. 3.1

      Delete Unused AWS Route53 Health Checks

      There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

      AWS Route53 is a scalable and highly available DNS service that connects user requests to infrastructure running in AWS and outside. One of its features is health checks, which monitor the health of your resources. Over time, as resources are added or removed, or configurations change, some health checks may no longer be associated with any active resources, leading to unnecessary costs and potential confusion. This runbook identifies and removes these orphaned health checks which helps in optimizing costs, reducing clutter, and ensuring that only relevant health checks are active in your AWS account

      3.1
      1. 3.1.1

        Get All AWS Route53 Health Checks

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

        This task retrieves a list of all health checks that have been configured in Amazon's Route53 service. AWS Route53 is a scalable and highly available domain name system (DNS) web service. A health check in Route53 monitors the health and performance of your web applications, web servers, and other resources. By fetching all health checks, users can review, manage, or diagnose the operational status and configuration of their resources, ensuring that the routing policies are working as expected. This can be especially useful for maintaining high availability and redundancy in distributed systems or for troubleshooting issues related to DNS routing.

        3.1.1
      2. 3.1.2

        Filter Out Unused Route53 Health Checks

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

        AWS Route53, Amazon's DNS service, offers health checks to monitor and report the availability of specific resources. Over time, with changes in configurations, deployments, or scaling activities, some of these health checks might become redundant, as they are no longer associated with active resources. Filtering out these unused health checks is an essential maintenance activity. By doing so, users can identify and potentially remove extraneous checks, helping streamline the management of their DNS configurations, optimize costs, and maintain a cleaner, more efficient environment.

        3.1.2
        1. 3.1.2.1

          Delete AWS Route53 Health Checks

          There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

          AWS Route53 is Amazon's DNS web service, and it provides health checks to monitor the health of resources and applications. Over time, as configurations change or resources are decommissioned, certain health checks might no longer be relevant or needed. Deleting these unnecessary Route53 health checks helps in decluttering the AWS environment, reducing potential costs, and simplifying management. It's essential to periodically review and delete any health checks that are no longer in use to maintain an optimized and streamlined AWS setup.

          3.1.2.1
    2. 3.2

      Clean up unused/unattached AWS Elastic IP addresses

      There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

      This runbook is designed to identify unattached Elastic IPs within all AWS regions and release them. Elastic IPs that are not associated with any instances can accumulate over time and result in unnecessary costs. By using this runbook, you can efficiently release these unattached Elastic IPs, optimizing your resources and reducing expenses

      3.2
      1. 3.2.1

        Filter out all unused/unattached AWS Elastic IP addresses

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

        This step involves searching through regions to identify Elastic IPs that are not currently associated with any instances. By iteratively querying each region's EC2 service, the script collects details about unattached Elastic IPs, including their public IP addresses, allocation IDs, and regions.

        3.2.1
        1. 3.2.1.1

          Release unused/unattached AWS Elastic IP addresses

          There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

          Once the unattached Elastic IPs are identified, this task releases them from the AWS environment. By using the collected allocation IDs and regions, the script communicates with the EC2 service to release each unattached Elastic IP. This process ensures that these IPs are no longer reserved, contributing to cost savings and resource optimization.

          3.2.1.1
        2. 3.2.1.2

          List and release all Elastic IPs in all regions

          There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

          This task is a combination of listing all Elastic IPs and releasing them if they are not associated with any instance all the while looping through all the regions.

          Note:- Even though the script is a one time stop for finding unattached Elastic IPs in all regions it takes relatively higher time to complete the process than the script focused on specified regions as it loops through all the regions.

          3.2.1.2
    3. 3.3

      Delete Underutilized AWS RDS Instances

      There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

      This runbook involves identifying Amazon RDS instances that consistently exhibit low CPU usage over a specific time frame and then safely removing them. By leveraging Amazon CloudWatch metrics, organizations can pinpoint underutilized RDS instances, set a CPU utilization threshold, and analyze instances that fall below this mark. Before initiating deletion, it's crucial to disable any active 'Deletion Protection' and to create a final snapshot as a backup measure. This proactive approach not only ensures cost efficiency by eliminating unnecessary expenses but also optimizes resource management within AWS.

      3.3
      1. 3.3.1

        List All AWS RDS Instances

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

        This task involves enumerating and displaying all AWS RDS (Amazon Relational Database Service) instances within an AWS account. This task is essential for management and auditing purposes, providing a clear view of all RDS instances. During this process, the script communicates with AWS services to retrieve information about each RDS instance, including their identifiers, status, and any other relevant details. This information is crucial for administrators to understand their AWS infrastructure's state, aiding in further actions like modification, deletion, or analysis of the RDS instances.

        3.3.1
      2. 3.3.2

        Filter out AWS RDS Instances with Low CPU Utilization

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

        This task identifies Amazon RDS instances that are underperforming or underutilized in terms of CPU usage. By utilizing Amazon CloudWatch metrics, users can monitor and assess the CPU performance of their RDS instances over a specified period. By setting a CPU utilization threshold, they can filter out instances that consistently operate below this limit, indicating potential over-provisioning or underuse. Highlighting these low-utilization instances aids organizations in optimizing their AWS resource allocation, ensuring cost efficiency and facilitating informed decisions about scaling or decommissioning certain database resources.

        3.3.2
        1. 3.3.2.1

          Delete AWS RDS Instance

          There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

          This task terminates the AWS RDS database and deletes all associated data. Before deletion, users often create a final snapshot to preserve the database's current state, enabling future restoration if necessary. It's essential to ensure that the "Deletion Protection" feature, designed to prevent accidental deletions, is disabled before proceeding. Once deleted, the RDS instance is no longer operational, and associated costs cease. However, any retained backups or snapshots will persist and may incur storage charges until they too are deleted.

          3.3.2.1
    4. 3.4

      Delete Underutilized AWS Redshift Clusters

      There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

      This runbook involves identifying Amazon Redshift clusters that have consistently low CPU utilization over a specified period and then deleting them to optimize resource usage and reduce costs. By monitoring the CPU metrics of Redshift clusters using Amazon CloudWatch, organizations can determine which clusters are underutilized and might be candidates for deletion or resizing. Deleting or resizing underutilized clusters ensures efficient use of resources and can lead to significant cost savings on cloud expenditures.

      3.4
      1. 3.4.1

        Get All AWS Redshift Clusters

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

        This process retrieves a list of all Amazon Redshift clusters within an AWS account. Amazon Redshift is a fully managed data warehouse service in the cloud that allows users to run complex analytic queries against petabytes of structured data. By fetching all Redshift clusters, users can gain insights into the number of active clusters, their configurations, statuses, and other related metadata. This information is crucial for administrative tasks, monitoring, and optimizing costs and performance.

        3.4.1
      2. 3.4.2

        Filter out Underutilized AWS Redshift Clusters

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

        This task pertains to identifying Amazon Redshift clusters that exhibit consistently low CPU utilization over a predefined time span. By leveraging Amazon CloudWatch metrics, organizations can detect underutilized Redshift clusters. Recognizing such clusters provides valuable insights, allowing teams to make informed decisions about potential downscaling, resource reallocation, or other optimization measures to ensure efficient cloud resource usage.

        3.4.2
        1. 3.4.2.1

          Delete AWS Redshift Clusters

          There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

          This task involves terminating specific Amazon Redshift clusters, effectively removing them from an AWS account. Deleting a Redshift cluster permanently erases all the data within the cluster and cannot be undone. This process might be undertaken to manage costs, decommission outdated data warehouses, or perform clean-up operations. It's crucial to ensure appropriate backups (snapshots) are in place before initiating a deletion to prevent accidental data loss.

          3.4.2.1
    5. 3.5

      Delete Unused Secrets from AWS Secrets Manager

      There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

      This runbook is designed to identify and remove secrets from the AWS Secrets Manager that haven't been accessed or utilized within a defined period (e.g., the past 90 days). Secrets Manager is a tool that helps manage sensitive information like API keys or database credentials. Over time, some secrets may become obsolete or unused, occupying unnecessary space and potentially incurring extra costs. This task automates the cleanup process by scanning for these dormant secrets and safely deleting them. Before executing this runbook, ensure proper AWS IAM permissions are set. Always use caution when deleting secrets to avoid unintended disruptions to applications or services.

      3.5
      1. 3.5.1

        Get All Secrets from AWS Secrets Manager

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

        This task retrieves a list of all secrets stored in the AWS Secrets Manager for your account. AWS Secrets Manager is a service designed to safeguard sensitive information such as database credentials and API keys. By executing this task, users will obtain a comprehensive list of secret names or ARNs, aiding in audit, management, or automation processes. Note that this task will list the secrets' identifiers, but not their actual values. To fetch a specific secret's value, additional steps involving the get_secret_value method are required. Ensure you have the appropriate AWS IAM permissions before executing this task.

        3.5.1
      2. 3.5.2

        Filter out Unused Secrets from AWS Secrets Manager

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

        This task aims to pinpoint secrets within AWS Secrets Manager that haven't been accessed for a specified duration, such as the past 90 days. Over time, certain secrets may not be referenced or utilized, indicating they may no longer be needed. By identifying these inactive secrets, organizations can assess their continued relevance, streamline their secrets inventory, and enhance security by minimizing potential exposure points. Before taking any action based on the results, it's crucial to review the list and ensure no critical secrets are mistakenly categorized as "unused."

        3.5.2
        1. 3.5.2.1

          Delete Secret from AWS Secrets Manager

          There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

          This task focuses on securely removing a specified secret from AWS Secrets Manager. Deleting secrets can be an essential step in managing sensitive information, especially if a secret is no longer in use or has been compromised. By executing this task, the targeted secret will be permanently erased from AWS Secrets Manager, ensuring it can't be accessed or retrieved. It's crucial to double-check the secret's relevance and backup any necessary data before deletion to prevent any unintended data loss or service disruptions.

          3.5.2.1
    6. 3.6

      Delete unused AWS CloudWatch Log Streams

      There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

      This runbook automates the process of identifying and deleting unused Amazon CloudWatch Log Streams. By scanning specified log groups across designated AWS regions, it efficiently detects log streams that have been inactive for a predetermined period. Once identified, these log streams are safely removed, helping organizations maintain a clutter-free logging environment and potentially reducing associated storage costs.

      3.6
      1. 3.6.1

        List all AWS CloudWatch Log Streams

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

        This task is designed to systematically retrieve and enumerate all CloudWatch log streams present in specified AWS regions. It offers a detailed snapshot of the existing log streams, enabling users to understand their logging landscape across various AWS services and applications.

        3.6.1
      2. 3.6.2

        Filter Unused AWS CloudWatch Log Streams

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

        This task examines CloudWatch log streams to identify those that have been inactive for a specified duration. By pinpointing these dormant streams, the task aids in maintaining a cleaner, more efficient logging environment and can subsequently assist in reducing unnecessary storage costs associated with retaining outdated logs on AWS CloudWatch.

        3.6.2
        1. 3.6.2.1

          Delete AWS CloudWatch Log Streams

          There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

          This task allows users to remove specified log streams from AWS CloudWatch. By executing this task, organizations can effectively manage and declutter their logging space, ensuring that only relevant and necessary logs are retained. This not only optimizes the logging environment but also helps in potentially reducing storage-associated costs on AWS.

          3.6.2.1
    7. 3.7

      Delete Unused AWS NAT Gateways

      There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

      This runbook identifies and removes inactive NAT gateways to optimize AWS costs. By eliminating unused resources, it streamlines infrastructure management and reduces unnecessary charges.

      3.7
      1. 3.7.1

        List All AWS NAT Gateways

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

        This task involves using the boto3 to programmatically iterate over all AWS regions, retrieve, and list details of all Network Address Translation (NAT) gateways present in an AWS account.

        3.7.1
      2. 3.7.2

        Filter Out Unused AWS NAT Gateways

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

        This task identifies AWS NAT gateways that have not transferred any data in the past week or threshold, deeming them as "unused", and filters them out for potential optimization or deletion.

        3.7.2
        1. 3.7.2.1

          Delete AWS NAT Gateways

          There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

          This task removes specified NAT gateways in an AWS environment. This cleanup optimizes network infrastructure, enhances security, and reduces costs by eliminating unused resources.

          3.7.2.1
    8. 3.8

      Stopping Underutilized AWS EC2 Instances

      There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

      In an AWS environment, EC2 instances incur charges based on their uptime. However, not all instances are actively utilized, leading to unnecessary expenses. Underutilized instances may have low CPU usage, minimal network activity, or other metrics indicating limited activity. Identifying and stopping such instances can result in significant cost savings. Tools like AWS Cost Explorer and third-party solutions can help identify these instances based on CloudWatch metrics. This runbook automates the process of monitoring and taking action on underutilized instances based on low CPU usage ensuring an optimized and cost-effective cloud environment. It's crucial, though, to ensure that stopping these instances won't disrupt essential services or applications.

      3.8
      1. 3.8.1

        Get all AWS EC2 instances

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

        Amazon Elastic Compute Cloud (EC2) is a service offered by Amazon Web Services (AWS) that provides resizable compute capacity in the cloud. Through Boto3's EC2 client, the describe_instances() method provides detailed information about each instance, including its ID, type, launch time, and current state. This capability assists users in effectively monitoring and managing their cloud resources.

        3.8.1
      2. 3.8.2

        Average CPU Utilizations of all AWS EC2 Instances

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.
        3.8.2
      3. 3.8.3

        Identify Idle AWS EC2 Instances

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

        AWS EC2 instances that are running but not actively used represent unnecessary costs. An "idle" EC2 instance typically exhibits very low metrics on parameters such as CPU utilization, network input/output, and disk read/writes. By leveraging AWS CloudWatch, users can monitor these metrics and identify instances that remain underutilized based on low CPU usage over extended periods. Once identified, these instances can either be stopped or terminated, leading to more efficient resource use and cost savings. It's important to analyze and verify the activity of these instances before taking action to ensure no critical processes are inadvertently affected.

        3.8.3
        1. 3.8.3.1

          Stop an AWS EC2 Instance

          There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

          In AWS, an EC2 instance can be in various states, including running, stopped, or terminated. Stopping an EC2 instance essentially means shutting it down, similar to turning off a computer. When an instance is stopped, it is not running, and therefore, you are not billed for instance usage. However, you are still billed for any EBS storage associated with the instance. The advantage of stopping, instead of terminating, is that you can start the instance again at any time. This capability is useful for scenarios where you want to temporarily halt operations without losing the instance configuration or data. It's essential to understand that stopping an instance will lead to the loss of the ephemeral storage content (Instance Store), but data on EBS volumes will remain intact.

          3.8.3.1
    9. 3.9

      Delete Unattached AWS EBS(Elastic Block Store) Volumes

      There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

      This runbook is designed to assist in the removal of unattached Amazon EBS Volumes within an AWS region. Once the EBS volume is deleted, the volume's data is permanently removed, and the volume cannot be attached to any instance. To preserve important data before deletion, you have the option to create a snapshot of the volume, allowing for potential volume recreation in the future.

      3.9
      1. 3.9.1

        Get Unattached AWS EBS Volumes

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

        This task involves identifying and filtering out Amazon Elastic Block Store (EBS) volumes that are not currently attached to any Amazon EC2 instances within a specific AWS region.

        3.9.1
        1. 3.9.1.1

          Create snapshots of unattached AWS EBS volumes

          There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

          This task streamlines the process of capturing point-in-time backups of EBS volumes that are not currently attached to instances. By creating snapshots, you can ensure data durability and recovery options, enabling you to safeguard valuable data and simplify data restoration if needed.

          3.9.1.1
        2. 3.9.1.2

          Delete Unattached EBS Volumes

          There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

          Efficiently manage your AWS Elastic Block Store (EBS) volumes by automating the deletion of unattached volumes. This task identifies EBS volumes that are not currently attached to any instances and removes them, helping you optimize storage resources and reduce unnecessary costs while maintaining your cloud infrastructure's cleanliness.

          3.9.1.2
    10. 3.10

      Delete low usage AWS EBS Volumes

      There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

      This runbook identifies Amazon Elastic Block Storage (EBS) volumes that exhibit low usage, and subsequently removes them. The process involves searching for EBS volumes that have been minimally utilized over a specified threshold period, and then performing the deletion for those volumes. This automation helps optimize storage resources by removing underutilized volumes, freeing up space and potentially reducing costs.

      3.10
      1. 3.10.1

        Filter out low usage AWS EBS volumes

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

        This task aims to identify Amazon Elastic Block Storage (EBS) volumes with minimal usage. It involves scanning through AWS resources to pinpoint EBS volumes that have been scarcely utilized over a predefined threshold period. This process can be crucial for optimizing storage resources and identifying opportunities to reduce costs, as it helps identify volumes that may no longer be necessary due to low activity levels.

        3.10.1
        1. 3.10.1.1

          Delete Detached EBS Volumes having low usage

          There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

          This task involves scanning through a list of EBS volumes and deleting them, provided they are not associated with any ec2 instances. Deleting these detached volumes that are no longer in use can help optimize storage resources and reduce unnecessary costs.

          3.10.1.1
    11. 3.11

      Delete AWS EBS Volumes attached to stopped EC2 instances

      There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

      This runbook streamlines resource management by identifying and removing Elastic Block Store (EBS) volumes linked to stopped Amazon EC2 instances. Through a sequential process, this automation retrieves EBS volumes associated with stopped instances and subsequently detaches and deletes them. This procedure aids in resource optimization and cost efficiency within the AWS environment.

      3.11
      1. 3.11.1

        Filter out EBS Volumes attached to stopped EC2 instances

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

        This is a task focused on identifying Elastic Block Store (EBS) volumes that are connected to Amazon EC2 instances currently in a stopped state by examining the instance-state and corresponding volume mappings.

        3.11.1
        1. 3.11.1.1

          Detach and Delete AWS EBS Volumes

          There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

          This task involves the removal of Elastic Block Store (EBS) volumes from their associated instances followed by the deletion of these volumes. In this particular task detachment and deletion of EBS volumes is related to stopped EC2 instances. It is executed to free up storage resources, enhance resource allocation efficiency, and optimize costs within the AWS infrastructure.

          3.11.1.1
    12. 3.12

      Filter Out and Delete Old AWS EBS Snapshots

      There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

      This runbook identifies and removes old Amazon Elastic Block Store (EBS) snapshots. By setting a specific age threshold it scans through designated AWS regions, pinpoints snapshots that surpass the age limit, and subsequently deletes them. This operation not only ensures efficient resource utilization but also aids in minimizing storage costs, promoting a cleaner and more cost-effective cloud environment.

      3.12
      1. 3.12.1

        Filter Out Old AWS EBS Snapshots

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

        This task identifies old Amazon Elastic Block Store (EBS) snapshots. By setting an age threshold, it scans across specified AWS regions, highlighting snapshots that exceed the set duration. This facilitates better management, paving the way for timely deletions and efficient storage utilization.

        3.12.1
        1. 3.12.1.1

          Delete AWS EBS Snapshots

          There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

          This task removes specified Amazon Elastic Block Store (EBS) snapshots. Designed to streamline storage management, this procedure efficiently purges selected snapshots across designated AWS regions, ensuring optimal resource utilization and reducing unnecessary storage costs.

          3.12.1.1
    13. 3.13

      Get unhealthy resources attached to AWS ELBs(Elastic Load Balancers)

      There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

      This runbook retrieves the list of resources, such as instances or targets, that are marked as 'unhealthy' or 'OutOfService', and are associated with AWS Elastic Load Balancers (ELB). This helps in identifying potential issues and ensuring the smooth operation and high availability of applications.

      3.13
      1. 3.13.1

        Get Unhealthy instances attached to Classic Load Balancers

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

        This task checks for instances which are OutOfService and are associated with a Classic Load Balancer.

        3.13.1
      2. 3.13.2

        Get Unhealthy targets associated to an ALB or NLB

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

        This task retrieves and lists targets that are marked as 'unhealthy' and linked to AWS Application Load Balancers (ALB) or Network Load Balancers (NLB). This process helps in detecting non-performing targets to maintain optimal load distribution and service availability.

        3.13.2
    14. 3.14

      Delete AWS ELBs with no targets or instances

      There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

      This runbook helps in identifying and removing Amazon Elastic Load Balancers (ELBs) that do not have any associated target groups or instances. ELBs play a crucial role in distributing traffic across instances, and if they are no longer serving a purpose due to the absence of targets or instances, it's recommended to remove them to optimize resources and reduce unnecessary costs. This process involves identifying such ELBs across specified AWS regions, displaying their details, and then, if applicable, deleting them to maintain an efficient and streamlined AWS environment.

      3.14
      1. 3.14.1

        Find AWS ELBs with No Targets or Instances

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

        This task identifies AWS Elastic Load Balancers (ELBs) that have no associated targets or instances. Such ELBs may indicate unused resources, leading to unnecessary costs. Checking and managing these can optimize AWS expenses.

        3.14.1
        1. 3.14.1.1

          Delete AWS ELBs

          There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

          This task deletes Amazon Elastic Load Balancers (ELBs) that are not associated with any targets or instances. These unattached ELBs could be remnants of previously deployed applications or services. By identifying and removing them, organizations can not only free up unused resources but also optimize their AWS infrastructure costs. This task helps maintain a clean and efficient cloud environment while ensuring cost-effectiveness.

          3.14.1.1
    15. 3.15

      Deleting AWS ECS(Elastic Container Service) clusters having low CPU Utilization

      There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

      This runbook is designed to efficiently manage AWS Elastic Container Service (ECS) resources. It scans specified AWS regions to identify ECS clusters with low average CPU utilization, based on a user-defined threshold. Once these underutilized clusters are identified, the runbook proceeds to delete them, thereby optimizing resource usage and potentially reducing operational costs.

      3.15
      1. 3.15.1

        Filter out AWS ECS Clusters having low CPU Utilization

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

        This task scans multiple AWS regions to identify ECS clusters that are underutilized in terms of CPU, based on a set threshold. This enables organizations to easily spot clusters that are consuming resources without delivering optimal performance, thereby helping in decision-making processes related to scaling, resource allocation, or decommissioning. This task aims to improve efficiency and reduce costs by flagging these low-activity clusters for further action.

        3.15.1
        1. 3.15.1.1

          Delete AWS ECS Clusters with low CPU Utilization

          There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

          This task removes specified ECS clusters, thereby helping organizations maintain a clean and efficient environment. This task is particularly useful for decommissioning clusters that are no longer needed, or that have been identified as underutilized, thereby contributing to cost savings and resource optimization. It ensures that all associated services and tasks within the clusters are properly terminated before removing the clusters themselves.

          3.15.1.1
    16. 3.16

      Cleanup inactive users in AWS IAM

      There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

      This runbook involves listing all IAM users, identifying those who haven't accessed AWS services for a specified period, and then safely deleting these inactive users. This process enhances security by removing potential vulnerabilities and optimizes resource usage in the AWS environment. Always proceed with caution to avoid unintended deletions.

      3.16
      1. 3.16.1

        List all AWS IAM Users

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

        This lists all IAM users in an AWS account, providing key details like usernames, user IDs, and creation dates. Essential for managing permissions and auditing access, this function supports security and compliance protocols by offering a clear view of user entities and their access levels. It's instrumental in enforcing security policies and the principle of least privilege in AWS resource access management.

        3.16.1
      2. 3.16.2

        Filter out inactive users AWS IAM Users

        There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

        This task identifies users who haven't accessed AWS services within a specified timeframe. This process helps to maintain a secure and well-organized IAM environment by focusing on active users and potentially deactivating or removing those who are no longer in use.

        3.16.2
        1. 3.16.2.1

          Delete an AWS IAM user

          There was a problem that the LLM was not able to address. Please rephrase your prompt and try again.

          This task deletes an IAM user in AWS which is a critical step in managing access to AWS resources. This process ensures that the user no longer has permission to perform actions or access resources. It involves several key steps: detaching all associated policies, removing any login profiles or access keys, and finally, deleting the user itself. This action is irreversible, and once the user is deleted, they cannot access the AWS Management Console, AWS CLI, or API operations unless recreated. Properly removing users helps in maintaining a secure and tidy AWS environment, especially when individuals no longer require access or have changed roles.

          3.16.2.1