Interview Prep/DevOps Fundamentals/Real-world scenarios

Your cloud bill doubled this month. How do you find out why and reduce it?

IntermediateScenarioReal-world scenarios
Answer

In one line: Use the cloud cost tools to find which services, accounts and resources grew, identify the cause (new resources, waste, data transfer, a misconfiguration or abuse), fix it, and add budgets, tags and alerts so you catch it earlier next time.

Step 1 — Find where the increase is

  • AWS Cost Explorer / Azure Cost Management / GCP Billing reports — group by service, account/subscription, region, and tag. Compare with last month.
  • Check daily cost: did it jump on one day (a specific change) or grow steadily?

Step 2 — Common causes

  1. Forgotten resources — test environments, big instances, GPU nodes or load balancers left running.
  2. Over-provisioning — instances or Kubernetes nodes far bigger than needed; low utilisation.
  3. Autoscaling gone wrong — max replicas too high, scaling never scales down.
  4. Data transfer — cross-AZ or cross-region traffic, NAT Gateway processing charges, internet egress.
  5. Storage growth — old snapshots, unattached EBS volumes, logs kept forever, S3 without lifecycle rules.
  6. Logging/monitoring costs — very verbose logs ingested into CloudWatch/Datadog.
  7. Security incident — compromised keys used for crypto mining in unused regions.

Step 3 — Reduce costs

  • Delete unused resources; schedule dev/test environments to shut down at night and weekends.
  • Right-size instances and Kubernetes requests based on actual usage.
  • Use Savings Plans / Reserved Instances for steady workloads and Spot instances for fault-tolerant ones (CI runners, batch jobs, some Kubernetes nodes via Karpenter).
  • Add S3 lifecycle policies (move to cheaper tiers, delete old data), snapshot retention policies.
  • Reduce data transfer: VPC endpoints for S3/ECR to avoid NAT charges, keep chatty services in the same AZ, use a CDN.
  • Reduce log volume and retention.

Step 4 — Prevent surprises (FinOps practices)

  • Tag everything (team, environment, service) and show cost per team.
  • Budgets and anomaly alerts (AWS Budgets, Cost Anomaly Detection).
  • Infracost in Terraform PRs to show cost changes before they happen.
  • Regular cost reviews with the teams who own the resources.

Example: a bill doubled because a load-testing EKS node group with 20 large instances was never deleted and NAT Gateway traffic grew from pulling images through the internet. Deleting the node group and adding an ECR VPC endpoint brought costs back down.

Tip for interviews: show both the investigation method and the prevention (tags, budgets, anomaly alerts).

All DevOps Fundamentals questions

More on Real-world scenarios