> ## Documentation Index
> Fetch the complete documentation index at: https://notes.kodekloud.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Disk Fill Scenario on EC2

> This article guides you through simulating a disk-fill failure on an EC2 instance using AWS Fault Injection Simulator to test application resilience.

In this walkthrough, you’ll create your first AWS Fault Injection Simulator (FIS) experiment against the PET Adoption website. By using the AWS FIS API to simulate a disk-fill failure on an EC2 instance, you’ll learn how your application responds to storage exhaustion in one Availability Zone (AZ). This test is crucial for validating your system’s resilience.

<Callout icon="lightbulb" color="#1CB2FE">
  * AWS CLI v2 configured with appropriate IAM permissions for FIS and EC2
  * Target PET Adoption environment deployed across multiple AZs
  * AWS FIS service enabled in your chosen region
</Callout>

## FIS Experiment Components

Before running the scenario, define the two core elements of any chaos experiment:

1. **Given**\
   The current architecture of the PET Adoption website includes:

   * EC2 instances distributed across multiple Availability Zones
   * An Elastic Load Balancer handling incoming traffic
   * An Auto Scaling Group maintaining desired instance count

   | Resource                    | Role                             |
   | --------------------------- | -------------------------------- |
   | EC2 instances (multi-AZ)    | Application web servers          |
   | Elastic Load Balancer (ELB) | Distributes traffic evenly       |
   | Auto Scaling Group (ASG)    | Scales instances based on demand |

2. **Hypothesis**\
   Injecting a disk-fill failure on a single EC2 instance in one AZ will **not** impact overall availability. With traffic routed to healthy instances in other AZs, the PET Adoption web page should remain responsive.

<Frame>
  ![The image illustrates a disk fill scenario on AWS EC2, showing a Virtual Private Cloud (VPC) setup with various components and a hypothesis that an EC2 disk filling up in a single availability zone will not affect application availability.](https://kodekloud.com/kk-media/image/upload/v1752871850/notes-assets/images/Chaos-Engineering-Disk-Fill-Scenario-on-EC2/aws-ec2-disk-fill-vpc-setup.jpg)
</Frame>

Next, we’ll walk through the step-by-step execution of this FIS experiment and verify whether our hypothesis holds true.

## References

* [AWS Fault Injection Simulator Documentation](https://docs.aws.amazon.com/fis/latest/userguide/)
* [AWS CLI FIS Commands](https://docs.aws.amazon.com/cli/latest/reference/fis/)

<CardGroup>
  <Card title="Watch Video" icon="video" cta="Learn more" href="https://learn.kodekloud.com/user/courses/chaos-engineering/module/822aac19-f6c1-4f39-bc41-59b523a98155/lesson/42443b6a-8f8c-4d3b-afa6-e9e70347730d" />
</CardGroup>
