Capacity planning basics
Topic: Monitoring basics
Summary
Use historical metrics and growth trends to plan for future capacity: when will disk, CPU, or memory be exhausted? Use this when sizing new systems or when deciding when to scale or upgrade to avoid running out of resources.
Intent: How-to
Quick answer
- Collect metrics over time (weeks to months). Plot usage (disk, CPU, memory) vs time; fit a trend (linear or growth rate). Estimate when usage will reach a threshold (e.g. 80% disk, sustained high CPU).
- Include growth events: new features, more users, or seasonal peaks. Plan buffer (e.g. scale when trend hits 70% in 30 days). Use capacity headroom alerts (e.g. 'disk will be full in 14 days at current rate').
- Document assumptions and review periodically. Automate where possible (e.g. Prometheus recording rules for trend); present to stakeholders so scaling or upgrade is scheduled before crunch.
Prerequisites
Steps
-
Gather history
Export or query metrics for disk, CPU, memory over 30–90 days. Identify trend: is usage growing linearly or in steps? Note any one-off events (migrations, traffic spikes).
-
Project and threshold
Extrapolate trend (simple linear or average growth rate). Calculate when usage will reach 80% (or your threshold). Add buffer (e.g. act when projection says 60 days to 80%).
-
Plan action
Schedule scale-up, upgrade, or cleanup before the projected date. If growth is variable, use a conservative estimate or alert when 'days until full' drops below 30.
-
Review and automate
Review projection monthly or quarterly; update assumptions. Use predictive alerts (e.g. 'disk full in 14 days') if your monitoring supports it; otherwise track in a spreadsheet or report.
Summary
Use historical metrics to project when resources will be exhausted; plan scaling or cleanup before that point. Use this for capacity planning and to avoid surprise shortages.
Prerequisites
Steps
Step 1: Gather history
Collect disk, CPU, and memory metrics over a sufficient period; identify trends and one-off events.
Step 2: Project and threshold
Extrapolate to estimate when usage will reach your threshold; add a safety buffer.
Step 3: Plan action
Schedule scaling, upgrade, or cleanup before the projected date.
Step 4: Review and automate
Review projections regularly; use predictive alerts if available.
Verification
- You have a projection and a planned action date; projections are updated and reviewed.
Troubleshooting
No history — Start collecting; use industry or workload benchmarks as a temporary proxy. Trend not linear — Use step or seasonal model; or use a conservative upper bound.