Course contentsShow
← Cloud and Infrastructure
Lesson 62 of 2,9892. Compute FoundationsFree lesson

VM States: Running, Stopped, Terminated

Understand the lifecycle states of VMs and how state transitions affect billing and data persistence.

VM States: Running, Stopped, Terminated

What you'll learn: How virtual machines transition through different lifecycle states and what each state means for your costs and data.

The Three Core VM States

Just like your laptop can be on, asleep, or completely shut down, virtual machines have distinct states that affect how you're billed and what happens to your data.

Running – Your VM is powered on and actively executing. The operating system is loaded, applications are working, and you're consuming compute resources. You pay for vCPU time, memory, and any associated resources. Think of this as your car's engine running—you're burning fuel.

Stopped – Your VM is powered off but still exists. The operating system is not running, and you're not charged for compute time (vCPU/memory). However, you still pay for attached storage volumes because your data persists on disk. This is like parking your car—you're not using gas, but you still own the vehicle and pay for parking.

Terminated – Your VM is permanently deleted. All associated resources are released, including ephemeral storage attached to the instance. Root volumes are typically deleted (unless configured otherwise), and you stop paying for everything. This is like selling your car—it's gone completely.

State Transitions and Billing Impact

When you stop a VM, your data on root and additional storage volumes remains intact (like we learned about VM storage). You can restart it later and pick up where you left off. However, dynamic IP addresses may change, and you continue paying for storage.

When you terminate a VM, there's no going back—it's permanent deletion. Any data on ephemeral volumes is lost forever.

Key Takeaway: Running VMs cost the most (compute + storage), stopped VMs cost less (storage only), and terminated VMs cost nothing but are gone forever—understanding these states helps you optimize cloud costs while protecting your data.