---
name: capacity-planning-prediction
description: Plan and predict infrastructure and application capacity needs using historical data, trending analysis, and forecasting models. Use when forecasting resource requirements, planning infrastructure scaling, analyzing growth trends, optimizing resource allocation, preventing capacity bottlenecks, budgeting for infrastructure growth, or conducting capacity reviews. Triggers on phrases like "capacity planning", "capacity forecast", "resource forecasting", "infrastructure scaling plan", "storage growth prediction", "compute capacity", "bandwidth planning", "capacity bottleneck", "growth trending", "right-sizing", "utilization forecast".
---

# Capacity Planning & Prediction

Forecast infrastructure, application, and network capacity requirements using data-driven analysis to prevent bottlenecks, optimize spending, and ensure service reliability.

## Workflow

1. Baseline current capacity: inventory all infrastructure resources (compute, storage, network, databases, applications) with current utilization metrics.
2. Collect historical data: gather 12-24 months of utilization metrics at granular intervals (5-min for compute, hourly for storage/databases, daily for network).
3. Identify growth drivers: business plans (new products, markets, M&A), seasonal patterns, user growth projections, data growth rates, transaction volume forecasts.
4. Apply forecasting models: linear regression for steady growth, exponential smoothing for seasonal patterns, machine learning for multi-variable predictions.
5. Establish capacity thresholds: warning at 70% utilization, critical at 85%, emergency at 95%; factor in burst capacity (typically 20-30% above baseline).
6. Generate capacity roadmap: 12-month monthly forecast, 24-month quarterly forecast, 36-month annual forecast with confidence intervals.
7. Develop scaling options: vertical scaling (upgrade), horizontal scaling (add nodes), architectural changes (caching, CDN, database sharding), cloud migration.
8. Calculate cost implications: CapEx for on-prem hardware, OpEx for cloud resources, total cost of ownership for each scaling option.
9. Present capacity plan to stakeholders: engineering leadership, finance, CIO/CDO; align with budget planning cycle.
10. Review and recalibrate quarterly: compare predictions to actuals; adjust growth factors; update forecasts.

## Capacity Baseline Assessment

```
INFRASTRUCTURE CAPACITY INVENTORY
===================================

COMPUTE RESOURCES:

  On-Premises Servers:
    → Physical servers: Count, CPU (cores, GHz), RAM (GB), storage (TB), age (years)
    → Virtual machines: vCPU allocation, RAM allocation, hypervisor (VMware vSphere, Hyper-V, KVM)
    → Utilization metrics (current):
       CPU: Average 45%, Peak 78% (business hours), Idle 22% (off-hours)
       Memory: Average 62%, Peak 85% (batch processing window)
       Disk I/O: Average 35%, Peak 65% (backup window)
    → Overhead: VMware vSphere ~5-10% hypervisor overhead; Hyper-V ~8-12%
    → Consolidation ratio: Current 8:1 (VMs per physical host); target 12:1 with new hardware

  Cloud Compute (AWS/Azure/GCP):
    → EC2/VMs: Instance types, count, utilization (CloudWatch/Azure Monitor)
    → Auto-scaling groups: Min/max/desired instances; current scale events/month
    → Reserved Instances: Coverage %, expiration dates, optimization opportunities
    → Serverless (Lambda/Functions): Invocations/month, average duration, memory usage
    → Cost per unit: $/vCPU-hour, $/GB-hour, cost per transaction

  Container/Orchestration:
    → Kubernetes clusters: Node count, CPU/memory requests vs. limits
    → Pod density: Average 45 pods/node; max 110 pods/node
    → Resource utilization: Requests 35% of allocatable (over-provisioned)
    → Horizontal pod autoscaler events: 120/month average

STORAGE RESOURCES:

  Data Storage:
    → SAN/NAS: Total capacity 500 TB, used 340 TB (68%), growth rate 15 TB/month
    → Storage tiers: Performance (SSD) 100 TB, capacity (HDD) 300 TB, archive 100 TB
    → File systems: Average utilization 62%; largest file server 87% full
    → Deduplication/ratio: Current 2.5:1; potential improvement to 3.5:1 with newer software
    → Projected exhaustion: Performance tier in 8 months at current growth

  Database Storage:
    → PostgreSQL: 25 TB total; 18 TB used; growth 400 GB/month
    → MongoDB: 8 TB total; 5 TB used; growth 200 GB/month (unindexed queries causing write amplification)
    → SQL Server: 15 TB total; 11 TB used; growth 250 GB/month
    → Backup storage: 40 TB; retention 90 days; growth 1 TB/month
    → Compression: Current ratio 3:1; TDE adds 0-5% overhead

  Cloud Storage:
    → S3/Azure Blob/GCS: 120 TB total; growth 8 TB/month
    → Lifecycle policies: Hot storage 60 TB, cool 35 TB, archive 25 TB
    → Cost optimization: 30% of data accessed <1x/month → candidate for archive tier
    → Estimated savings: $18K/month from tier migration

NETWORK RESOURCES:

  Internet Connectivity:
    → Primary: 10 Gbps fiber (utilized avg 4.2 Gbps, peak 7.8 Gbps)
    → Secondary: 5 Gbps fiber (failover; tested quarterly)
    → CDN: CloudFront/Akamai; 60% of traffic served from edge (saves ~3.5 Gbps origin bandwidth)
    → Projected exhaustion: Peak approaching 80% of primary; upgrade to 20 Gbps needed in 6 months

  Internal Network:
    → Core switch capacity: 40 Gbps (utilized 65% during peak)
    → Data center interconnect: 100 Gbps (utilized 25%)
    → Branch WAN links: 25 branches × 1 Gbps each (avg utilization 35%)
    → SD-WAN: Active for 18/25 branches; MPLS optimization saving 22% on WAN costs

  Wireless:
    → Wi-Fi 6 APs: 120 access points across campus
    → Concurrent users: Avg 800, peak 1,200 (meeting rooms bottleneck)
    → Bandwidth: 5 GHz band 85% utilized during peak; 2.4 GHz congested
    → Upgrade plan: Wi-Fi 7 deployment in high-density areas (Q3)
```

## Forecasting Models and Methods

```
CAPACITY FORECASTING METHODOLOGY
==================================

MODEL SELECTION BY PATTERN:

  1. Linear Regression (Steady Growth):
     → Use when: Consistent monthly growth (R² > 0.85)
     → Formula: Capacity(t) = Current + (Monthly Growth Rate × Months)
     → Example: Storage growing 15 TB/month → 12 months = 180 TB additional
     → Confidence: High for 0-12 months; moderate for 12-24 months
     → Limitations: Does not account for seasonality or step changes

  2. Exponential Smoothing (Seasonal Patterns):
     → Use when: Regular seasonal patterns (quarterly, monthly, weekly)
     → Method: Holt-Winters triple exponential smoothing
     → Captures: Level, trend, and seasonal components
     → Example: E-commerce compute peaks 300% above baseline during holiday quarter
     → Configuration:
        Alpha (level smoothing): 0.3
        Beta (trend smoothing): 0.1
        Gamma (seasonal smoothing): 0.2
     → Tools: Python (statsmodels), R (forecast package), Azure Time Series Insights

  3. Time Series Analysis (Multi-Variable):
     → Use when: Multiple correlated variables affect capacity
     → Method: ARIMA (AutoRegressive Integrated Moving Average)
     → Variables: User count, transaction volume, data volume, business events
     → Tools: Prometheus + Grafana, Datadog Anomaly Detection, AWS Forecast

  4. Machine Learning Forecasting:
     → Use when: Complex patterns, multiple factors, large historical datasets
     → Method: Prophet (Facebook), XGBoost, LSTM neural networks
     → Features: Day of week, holidays, marketing events, product launches, seasonality
     → Accuracy: Typically 85-95% within 12-month horizon
     → Retrain: Monthly with latest data; A/B test model versions

  5. Scenario-Based Planning:
     → Use when: High uncertainty (new markets, product pivots, M&A)
     → Scenarios: Base case (70% probability), optimistic (15%), pessimistic (15%)
     → Capacity planning for each scenario
     → Flexible infrastructure: Auto-scaling, spot instances, on-demand capacity

FORECASTING HORIZONS AND ACCURACY:

  Short-term (0-3 months):
    → Accuracy: ±5-10%
    → Method: Trend extrapolation + business event adjustments
    → Action: Immediate procurement, scaling decisions

  Medium-term (3-12 months):
    → Accuracy: ±10-20%
    → Method: Seasonal decomposition + ML models
    → Action: Budget planning, hardware procurement (lead time 8-12 weeks)

  Long-term (12-36 months):
    → Accuracy: ±20-35%
    → Method: Scenario-based + business strategy alignment
    → Action: Strategic planning, data center decisions, cloud contract negotiations

GROWTH DRIVERS MAPPING:

  Business-Driven:
    → User growth rate: 25% YoY → capacity impact calculated per user
    → Revenue growth: 30% YoY → correlate with infrastructure growth (typically 20-40%)
    → New product launch: Estimated capacity requirements per product roadmap
    → Market expansion: Geographic replication requirements
    → M&A: Target company infrastructure assessment and integration plan

  Technology-Driven:
    → Data retention policy changes: Extended retention → storage growth
    → Feature releases: New features → compute/memory/network impact
    → Security upgrades: Encryption → 5-15% storage overhead; TLS → CPU overhead
    → Compliance requirements: Additional logging → storage growth; replication → bandwidth
```

## Capacity Thresholds and Alerting

```
CAPACITY THRESHOLD FRAMEWORK
==============================

UTILIZATION THRESHOLDS BY RESOURCE TYPE:

  CPU / Compute:
    → Normal: 0-60% (headroom for burst workloads)
    → Warning: 60-75% (plan scaling within 30 days)
    → Critical: 75-85% (scale within 7 days; performance degradation likely)
    → Emergency: 85%+ (immediate scaling required; risk of SLA breach)
    → Burst capacity: 20-30% above baseline for 15-minute peaks

  Memory / RAM:
    → Normal: 0-70% (application working set + headroom)
    → Warning: 70-80% (plan memory upgrade within 30 days)
    → Critical: 80-90% (swap usage increases; performance impact within 7 days)
    → Emergency: 90%+ (OOM kills possible; immediate action required)
    → Note: Memory thresholds stricter than CPU due to swap performance penalty

  Storage / Disk:
    → Normal: 0-60%
    → Warning: 60-75% (plan expansion; notify procurement)
    → Critical: 75-85% (order expansion; cleanup low-value data)
    → Emergency: 85-95% (immediate expansion; risk of service outage)
    → Note: File systems fail at 100%; XFS/EXT4 degraded performance at >90%
    → Backup storage: Separate thresholds; 80% = warning; 90% = critical

  Network / Bandwidth:
    → Normal: 0-50% (sustained; allows burst)
    → Warning: 50-70% (monitor trending; plan upgrade)
    → Critical: 70-85% (packet loss possible; upgrade needed)
    → Emergency: 85%+ (packet loss occurring; service degradation)
    → Burst: 20% burst capacity for short periods (1-5 minutes)

  Database:
    → Connection pool: Warning at 60%, critical at 80%
    → IOPS: Warning at 65% of provisioned, critical at 85%
    → Replication lag: Warning >5 seconds, critical >30 seconds
    → Table space: Warning at 70%, critical at 85%
    → Query performance: Slow query rate >1% = warning; >5% = critical

AUTOMATED ALERTING CONFIGURATION:

  Alert Channels:
    → Warning: Email notification to capacity planning team; ticket created
    → Critical: PagerDuty/Opsgenie alert to on-call engineer; Slack #capacity-critical
    → Emergency: Page to engineering manager + CTO; bridge call activated

  Alert Suppression:
    → Maintenance windows: Suppress during planned maintenance (pre-registered)
    → Known issues: Suppress if related ticket already open
    → Correlation: Deduplicate correlated alerts (same root cause)

  Escalation Policy:
    → Warning: Acknowledge within 4 hours; plan action within 5 business days
    → Critical: Acknowledge within 30 minutes; mitigation within 4 hours
    → Emergency: Acknowledge within 10 minutes; mitigation within 1 hour
```

## Capacity Roadmap and Planning

```
12-MONTH CAPACITY ROADMAP TEMPLATE
=====================================

COMPUTE CAPACITY ROADMAP:

  Current State (Month 0):
    → On-prem: 45 physical servers, 380 VMs, 8:1 consolidation ratio
    → Cloud: 240 EC2 instances, 8 auto-scaling groups, 150 Lambda functions
    → Containers: 3 K8s clusters, 45 nodes, 2,400 pods

  Growth Forecast:
    → Month 3: +15% compute (Q2 product launch); peak utilization 72%
    → Month 6: +25% compute (Q3 international expansion); peak utilization 78%
    → Month 9: +35% compute (Q4 holiday season + new features); peak utilization 82%
    → Month 12: +40% compute (steady state growth); peak utilization 80%

  Scaling Actions:
    → Month 2: Procure 10 new physical servers (lead time 8 weeks); deploy for Q2
    → Month 5: Increase cloud auto-scaling max from 40 to 60 instances
    → Month 6: Add K8s cluster for new market; 20 nodes
    → Month 8: Migrate 50 legacy VMs to containers (improve consolidation to 12:1)
    → Month 10: Purchase RI coverage for 24-month term (30% cost savings)

  Budget Impact:
    → CapEx: $250K for 10 physical servers (one-time)
    → OpEx: $45K/month increase in cloud compute (phased)
    → Savings: $38K/month from RI and optimization
    → Net annual cost increase: $420K

STORAGE CAPACITY ROADMAP:

  Current State: 500 TB total, 340 TB used, 15 TB/month growth
  Exhaustion: Performance tier (100 TB) in 8 months; overall in 11 months

  Actions:
    → Month 1: Implement deduplication improvement (3.5:1 ratio); saves 60 TB
    → Month 2: Migrate 30 TB to archive tier (accessed <1x/month)
    → Month 4: Procure 200 TB additional performance tier
    → Month 6: Implement data lifecycle policies (auto-archival after 180 days)
    → Month 9: Review data retention policies with legal (potential reduction)

  Budget:
    → CapEx: $180K for 200 TB performance storage
    → OpEx savings: $12K/month from archival migration

NETWORK CAPACITY ROADMAP:

  Current: 10 Gbps primary, peak 7.8 Gbps (78% utilization)
  Exhaustion: Peak capacity in ~4 months at current growth

  Actions:
    → Month 3: Upgrade CDN coverage from 60% to 75% (saves 1.5 Gbps origin)
    → Month 4: Upgrade primary to 20 Gbps (vendor lead time: 6 weeks)
    → Month 6: Deploy SD-WAN to remaining 7 branches (optimize WAN traffic)
    → Month 9: Evaluate 5G backup connectivity for key offices

  Budget:
    → OpEx increase: $8K/month for 20 Gbps (vs. $5K for 10 Gbps)
    → CDN increase: $3K/month for expanded coverage
```

## Integration Points

- **Datadog**: Infrastructure monitoring with capacity forecasting; anomaly detection; multi-cloud support; $23/host/month
- **Dynatrace**: AI-driven capacity planning with Davis engine; predictive scaling recommendations; full-stack observability
- **Azure Capacity Planner / AWS Cost Explorer**: Cloud-native capacity and cost forecasting; utilization recommendations; reserved instance optimization
- **VMware vRealize Operations**: On-prem VMware capacity planning; consolidation recommendations; predictive alerts; chargeback/showback
- **SolarWinds Storage Resource Monitor**: Storage capacity planning; growth trending; threshold alerting; SAN/NAS support
- **Prometheus + Grafana**: Open-source capacity monitoring; custom dashboards; alerting; recording queries for forecasting
- **ServiceNow ITBM**: Business-aligned capacity planning; financial modeling; service catalog integration; chargeback
- **Custom ML models**: Python (Prophet, scikit-learn, TensorFlow) for advanced forecasting; integrates with monitoring APIs

## Edge Cases

- **Sudden traffic spikes**: Viral events, PR campaigns, flash sales — capacity planning cannot predict; implement auto-scaling with aggressive thresholds; maintain 40% burst capacity for cloud workloads
- **Legacy systems unable to scale vertically**: Old databases/applications with maxed-out hardware; plan migration path; add read replicas; implement caching layer; temporary workaround before full modernization
- **Multi-cloud capacity complexity**: Different forecasting per provider; inconsistent metrics; unified dashboard required; avoid vendor lock-in while maintaining capacity visibility
- **Data growth from compliance changes**: New regulations mandating extended retention (e.g., 7-year instead of 3-year); immediate storage impact; negotiate archival pricing; implement tiered storage aggressively
- **Seasonal business with extreme variance**: Retail (300% holiday spike) or tax services (Q1 spike); over-provision for peak → massive waste for 9 months; solution: cloud burst capacity, spot instances, temporary staffing
- **M&A infrastructure integration**: Rapid capacity assessment of acquired company; 90-day integration plan; potential decommissioning of redundant systems; data migration capacity planning
- **Edge computing capacity**: Distributed edge locations with limited resources; local capacity constraints; predictive caching; edge-to-cloud data pipeline sizing
