Install
openclaw skills install capacity-plannerForecast infrastructure capacity needs using historical metrics, growth projections, and cost modeling. Identify bottlenecks before they cause outages and right-size resources to avoid over-provisioning.
openclaw skills install capacity-plannerForecast when your infrastructure will hit limits. Analyze historical metrics (CPU, memory, disk, network, database connections), project growth curves, identify approaching bottlenecks, and recommend right-sizing — so you scale proactively instead of reactively.
Use when: "when will we run out of space", "capacity forecast", "right-size our instances", "are we over-provisioned", "plan for traffic growth", "infrastructure scaling plan", "when do we need to upgrade", or before budget planning.
forecast — Project Resource Exhaustion# Prometheus — CPU utilization over last 30 days
curl -s "$PROMETHEUS_URL/api/v1/query_range" \
--data-urlencode 'query=avg(rate(node_cpu_seconds_total{mode!="idle"}[5m])) by (instance)' \
--data-urlencode "start=$(date -d '30 days ago' +%s)" \
--data-urlencode "end=$(date +%s)" \
--data-urlencode 'step=1h' | python3 -c "
import json, sys
data = json.load(sys.stdin)
for result in data['data']['result']:
instance = result['metric']['instance']
values = [float(v[1]) for v in result['values']]
avg = sum(values) / len(values)
peak = max(values)
trend = (values[-1] - values[0]) / len(values) # slope per hour
print(f'{instance}: avg={avg:.1%} peak={peak:.1%} trend={trend:+.4%}/hr')
"
# Disk usage over time
df -h / /data /var 2>/dev/null
# Historical disk growth (if monitoring available)
curl -s "$PROMETHEUS_URL/api/v1/query_range" \
--data-urlencode 'query=node_filesystem_avail_bytes{mountpoint="/"}' \
--data-urlencode "start=$(date -d '30 days ago' +%s)" \
--data-urlencode "end=$(date +%s)" \
--data-urlencode 'step=1d'
# Memory usage
free -h
# Database connections
curl -s "$PROMETHEUS_URL/api/v1/query" \
--data-urlencode 'query=pg_stat_activity_count / pg_settings_max_connections'
If Prometheus unavailable, use CloudWatch, Datadog, or system tools:
# Last 30 days of CloudWatch CPU
aws cloudwatch get-metric-statistics --namespace AWS/EC2 \
--metric-name CPUUtilization --statistics Average Maximum \
--dimensions Name=InstanceId,Value=i-0abc123 \
--start-time $(date -d '30 days ago' -u +%Y-%m-%dT%H:%M:%SZ) \
--end-time $(date -u +%Y-%m-%dT%H:%M:%SZ) --period 86400
For each resource, determine growth pattern:
Calculate days until exhaustion:
days_remaining = (capacity - current_usage) / daily_growth_rate
For exponential: use doubling time to project.
# Capacity Forecast Report — [date]
## Critical (exhaustion < 30 days)
| Resource | Current | Capacity | Growth/day | Exhaustion | Action |
|----------|---------|----------|------------|------------|--------|
| Disk (/) | 45 GB | 50 GB | 180 MB/day | ~28 days | Expand volume or add cleanup cron |
| DB connections | 85/100 | 100 | +2/week | ~5 weeks | Increase max_connections or add pgbouncer |
## Warning (exhaustion 30-90 days)
| Resource | Current | Capacity | Growth/day | Exhaustion |
|----------|---------|----------|------------|------------|
| Memory | 12/16 GB | 16 GB | 50 MB/day | ~82 days |
## Healthy (>90 days or no growth)
- CPU: avg 35%, peak 72%, flat trend — no action needed
- Network: avg 200 Mbps of 1 Gbps — no concern
## Over-Provisioned (wasting money)
| Resource | Used | Provisioned | Utilization | Savings |
|----------|------|-------------|-------------|---------|
| worker-pool-3 | 2 vCPU avg | 8 vCPU | 25% | Downsize to 4 vCPU, save ~$150/mo |
| Redis cluster | 512 MB | 8 GB | 6% | Downsize to 2 GB, save ~$80/mo |
rightsize — Recommend Instance SizesGiven current utilization and growth projections:
cost-model — Project Infrastructure CostsGiven the capacity forecast:
bottleneck — Identify Scaling BottlenecksAnalyze the system for the component that will fail first under load:
Rank bottlenecks by "time to impact" and recommend mitigation order.