Amazon EKS · Lesson 9 of 11 · 3 min read
Cost optimisation and multi-tenancy
Where EKS money goes
Nodes (usually the bulk), NAT gateway data processing, cross-AZ data transfer, load balancers, EBS volumes and snapshots, CloudWatch logs/metrics ingestion, and the per-cluster fee (×3–4 in extended support).
Levers
- Right-size requests — the scheduler packs by requests, so inflated requests waste nodes. Compare requests vs actual usage (Kubecost/OpenCost, Container Insights, VPA recommendations).
- Karpenter consolidation and diverse instance types; Spot for stateless and batch workloads; Graviton for ~20% savings; Savings Plans for the on-demand baseline.
- Scale dev/test to zero outside working hours (KEDA cron, Karpenter limits, scheduled scaling) and delete idle clusters.
- One ALB for many services via IngressGroups.
- VPC endpoints (S3 gateway, ECR) to cut NAT charges; topology-aware routing to reduce cross-AZ traffic.
- Log volume control — drop debug logs, set retention.
- Stay on standard support versions.
"Cost spiked after moving to EKS — where do you look?" — node utilisation (requests vs usage), NAT and cross-AZ data in Cost Explorer, number of load balancers, idle dev clusters, on-demand vs Spot mix, logging volume.
Enlarge diagram
Swipe sideways to see all of it, or tap to open it full screen.
Multi-tenant cluster design
For several teams on one cluster:
- Namespace per team/app, with labels for ownership and cost allocation.
- Access entries/RBAC scoped to namespaces.
- ResourceQuotas and LimitRanges per namespace.
- NetworkPolicies — default deny between namespaces.
- Policy engine — Kyverno/Gatekeeper guardrails; PSA restricted.
- Separate node pools (taints/tolerations or Karpenter NodePools) for teams with special or noisy workloads.
- Cost allocation by namespace/labels (Kubecost, split cost allocation data for EKS in AWS CUR).
- For hard isolation (compliance, untrusted tenants), separate clusters or accounts instead.
Enlarge diagram
Swipe sideways to see all of it, or tap to open it full screen.